/* Social Publisher admin UI */

.calliope-sp-wrap {
  --calliope-sp-bg: #f6f8fb;
  --calliope-sp-surface: #ffffff;
  --calliope-sp-surface-soft: #f9fbff;
  --calliope-sp-text: #1f2a44;
  --calliope-sp-heading: #374a72;
  --calliope-sp-muted: #667085;
  --calliope-sp-border: #d8e0ee;
  --calliope-sp-border-strong: #b9c6dd;
  --calliope-sp-cyan: #0baee3;
  --calliope-sp-blue: #346bdd;
  --calliope-sp-purple: #7218cb;
  --calliope-sp-purple-dark: #56149d;
  --calliope-sp-purple-mid: #8f2fda;
  --calliope-sp-purple-soft: #f5efff;
  --calliope-sp-pink: #f23dc5;
  --calliope-sp-danger: #b42318;
  --calliope-sp-danger-soft: #fff4f3;
  --calliope-sp-success: #16875a;
  --calliope-sp-warning: #9a6a00;
  --calliope-sp-radius: 8px;
  --calliope-sp-shadow: 0 10px 28px rgba(31, 42, 68, 0.08);
  --calliope-sp-shadow-soft: 0 4px 14px rgba(31, 42, 68, 0.06);
  --calliope-sp-focus: 0 0 0 3px rgba(114, 24, 203, 0.18);
  color: var(--calliope-sp-text);
  padding-bottom: 36px;
}

.calliope-sp-wrap * {
  box-sizing: border-box;
}

.calliope-sp-wrap a {
  color: var(--calliope-sp-purple);
}

.calliope-sp-wrap .notice {
  max-width: 1180px;
  margin: 12px auto;
}

/* Header */
.calliope-sp-wrap .calliope-sp-topbar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  max-width: 1180px;
  margin: 14px auto 12px;
  padding: 13px 18px 12px;
  overflow: hidden;
  background: linear-gradient(180deg, #ffffff 0%, #fbf8ff 100%);
  border: 1px solid #dfd2f4;
  border-radius: var(--calliope-sp-radius);
  box-shadow: 0 8px 22px rgba(86, 20, 157, 0.08);
}


.calliope-sp-wrap .calliope-sp-topbar__brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  flex: 1 1 auto;
}

.calliope-sp-wrap .calliope-sp-topbar__logo-clean {
  display: block;
  width: min(179px, 24vw);
  max-width: 100%;
  height: auto;
  flex: 0 0 auto;
  margin: 0;
  border: 0;
  box-shadow: none;
  background: transparent;
}

.calliope-sp-wrap .calliope-sp-topbar__copy {
  min-width: 0;
  max-width: 600px;
  padding-left: 14px;
  border-left: 1px solid #ded2f1;
}

.calliope-sp-wrap .calliope-sp-topbar__copy p {
  margin: 0;
  color: var(--calliope-sp-muted);
  font-size: 12.5px;
  line-height: 1.45;
}

.calliope-sp-wrap .calliope-sp-topbar__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
  flex: 0 0 auto;
  flex-wrap: wrap;
}

.calliope-sp-wrap .calliope-sp-topbar__button,
.calliope-sp-wrap .calliope-sp-review-box__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid var(--calliope-sp-purple);
  border-radius: var(--calliope-sp-radius);
  background: var(--calliope-sp-purple);
  color: #fff;
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  transition: background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, color 0.16s ease;
}

.calliope-sp-wrap .calliope-sp-topbar__button:hover,
.calliope-sp-wrap .calliope-sp-review-box__button:hover {
  color: #fff;
  background: var(--calliope-sp-purple-dark);
  border-color: var(--calliope-sp-purple-dark);
  box-shadow: 0 0 0 3px rgba(114, 24, 203, 0.16);
}

/* Primary tabs: allow clean multi-row navigation instead of horizontal scrolling. */
.calliope-sp-wrap .nav-tab-wrapper {
  max-width: 1180px;
  width: min(100%, 1180px);
  margin: 0 auto 12px !important;
  padding: 0 0 8px;
  border-bottom: 1px solid var(--calliope-sp-border);
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  justify-content: flex-start;
  column-gap: 6px;
  row-gap: 6px;
  overflow: visible;
}

.calliope-sp-wrap .nav-tab {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 42px;
  min-width: max-content;
  margin: 0;
  padding: 0 11px;
  border: 1px solid transparent;
  border-bottom: 2px solid transparent;
  border-radius: var(--calliope-sp-radius);
  background: transparent;
  color: var(--calliope-sp-muted);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.calliope-sp-wrap .nav-tab:hover {
  background: #fff;
  color: var(--calliope-sp-heading);
}

.calliope-sp-wrap .nav-tab-active {
  background: #fff;
  border-color: var(--calliope-sp-border);
  border-bottom-color: var(--calliope-sp-purple);
  color: var(--calliope-sp-heading);
}

/* Context navigation for secondary Pro areas that belong to a primary tab. */
.calliope-sp-wrap .calliope-sp-context-nav {
  max-width: 1180px;
  width: min(100%, 1180px);
  margin: -2px auto 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.calliope-sp-wrap .calliope-sp-context-nav__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 999px;
  background: #fff;
  color: var(--calliope-sp-muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  box-shadow: none;
}

.calliope-sp-wrap .calliope-sp-context-nav__link:hover,
.calliope-sp-wrap .calliope-sp-context-nav__link:focus {
  color: var(--calliope-sp-heading);
  border-color: #c8b7de;
  outline: none;
}

.calliope-sp-wrap .calliope-sp-context-nav__link.is-active {
  color: var(--calliope-sp-heading);
  border-color: rgba(114, 24, 203, 0.35);
  background: rgba(114, 24, 203, 0.07);
}

.calliope-sp-wrap .nav-tab .dashicons {
  width: 17px;
  height: 17px;
  font-size: 17px;
  line-height: 1;
  color: inherit;
}

/* Page layout */
.calliope-sp-wrap .calliope-sp-panel {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.calliope-sp-wrap .calliope-sp-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr);
  gap: 20px;
  align-items: start;
}

.calliope-sp-wrap .calliope-sp-publication-type-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr);
  gap: 20px;
  align-items: start;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.calliope-sp-wrap .calliope-sp-publication-type-layout > .calliope-spp-publication-type {
  grid-column: 1;
  width: 100%;
  max-width: none;
  min-width: 0;
}

.calliope-sp-wrap .calliope-sp-composer-grid > * {
  min-width: 0;
}

.calliope-sp-wrap .calliope-sp-image-card {
  align-self: start;
}

.calliope-sp-wrap .calliope-sp-composer-section {
  width: 100%;
  margin-top: 16px;
}

.calliope-sp-wrap .calliope-sp-composer-section > .calliope-sp-card {
  width: auto;
}

.calliope-sp-wrap .calliope-sp-publish-actions-card {
  padding-top: 14px;
  padding-bottom: 14px;
}

.calliope-sp-wrap .calliope-sp-info-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  margin-top: 16px;
}

.calliope-sp-wrap .calliope-sp-card {
  background: var(--calliope-sp-surface);
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  box-shadow: var(--calliope-sp-shadow-soft);
  padding: 18px;
}

.calliope-sp-wrap .calliope-sp-card h3 {
  margin: 0 0 12px;
  color: var(--calliope-sp-heading);
  font-size: 15px;
  line-height: 1.35;
  font-weight: 700;
}

.calliope-sp-wrap .calliope-sp-anchor-card {
  scroll-margin-top: 24px;
}

/* Typography helpers */
.calliope-sp-wrap .calliope-sp-muted {
  color: var(--calliope-sp-muted);
}

.calliope-sp-wrap .calliope-sp-hint,
.calliope-sp-wrap .calliope-sp-mini {
  margin-top: 6px;
  color: var(--calliope-sp-muted);
  font-size: 12px;
  line-height: 1.45;
}

.calliope-sp-wrap .calliope-sp-divider {
  height: 1px;
  margin: 16px 0;
  background: var(--calliope-sp-border);
}

.calliope-sp-wrap code {
  border-radius: 4px;
}

/* Forms */
.calliope-sp-wrap label {
  display: inline-block;
  margin-bottom: 4px;
  color: var(--calliope-sp-heading);
  font-weight: 700;
}

.calliope-sp-wrap .calliope-sp-field {
  margin: 0 0 14px;
}

.calliope-sp-wrap input[type="text"],
.calliope-sp-wrap input[type="url"],
.calliope-sp-wrap input[type="password"],
.calliope-sp-wrap input[type="number"],
.calliope-sp-wrap input[type="search"],
.calliope-sp-wrap textarea,
.calliope-sp-wrap select {
  max-width: 100%;
  border-color: var(--calliope-sp-border-strong);
  border-radius: var(--calliope-sp-radius);
  color: var(--calliope-sp-text);
  box-shadow: none;
}

.calliope-sp-wrap .calliope-sp-field input[type="text"],
.calliope-sp-wrap .calliope-sp-field input[type="url"],
.calliope-sp-wrap .calliope-sp-field input[type="password"],
.calliope-sp-wrap .calliope-sp-field input[type="number"],
.calliope-sp-wrap .calliope-sp-field input[type="search"],
.calliope-sp-wrap .calliope-sp-field textarea,
.calliope-sp-wrap .calliope-sp-field select {
  width: 100%;
}

.calliope-sp-wrap .calliope-sp-input-suffix {
  display: flex;
  align-items: stretch;
  width: 100%;
  overflow: hidden;
  border: 1px solid var(--calliope-sp-border-strong);
  border-radius: var(--calliope-sp-radius);
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.calliope-sp-wrap .calliope-sp-input-suffix:focus-within {
  border-color: var(--calliope-sp-purple);
  box-shadow: var(--calliope-sp-focus);
}

.calliope-sp-wrap .calliope-sp-field .calliope-sp-input-suffix input[type="text"] {
  flex: 1 1 auto;
  min-width: 0;
  width: auto;
  margin: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.calliope-sp-wrap .calliope-sp-field .calliope-sp-input-suffix input[type="text"]:focus {
  border-color: transparent;
  box-shadow: none;
  outline: none;
}

.calliope-sp-wrap .calliope-sp-input-suffix__text {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  padding: 0 13px;
  border-left: 1px solid var(--calliope-sp-border);
  background: #f6f7f7;
  color: var(--calliope-sp-text);
  font-weight: 700;
  white-space: nowrap;
}

.calliope-sp-wrap textarea {
  min-height: 116px;
  resize: vertical;
}

.calliope-sp-wrap input:focus,
.calliope-sp-wrap textarea:focus,
.calliope-sp-wrap select:focus {
  border-color: var(--calliope-sp-purple);
  box-shadow: var(--calliope-sp-focus);
  outline: none;
}

/* Buttons */
.calliope-sp-wrap .calliope-sp-actions,
.calliope-sp-wrap .calliope-sp-row {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
}

.calliope-sp-wrap .calliope-sp-actions {
  margin-top: 12px;
}

.calliope-sp-wrap .button {
  border-radius: var(--calliope-sp-radius);
  font-weight: 700;
  transition: background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, color 0.16s ease, transform 0.16s ease;
}

.calliope-sp-wrap .calliope-sp-log-actions {
  align-items: flex-start;
}

.calliope-sp-wrap .calliope-sp-log-actions form {
  margin: 0;
}

.calliope-sp-wrap .calliope-sp-log-actions .button {
  border-color: var(--calliope-sp-purple);
  color: var(--calliope-sp-purple);
}

.calliope-sp-wrap .calliope-sp-log-actions .button:hover,
.calliope-sp-wrap .calliope-sp-log-actions .button:focus {
  border-color: var(--calliope-sp-purple-dark);
  color: var(--calliope-sp-purple-dark);
}

.calliope-sp-wrap .button.button-primary,
.calliope-sp-wrap .button.button-primary.calliope-sp-cta,
.calliope-sp-wrap .button.button-secondary.calliope-sp-dark {
  border-color: transparent;
  background: linear-gradient(135deg, var(--calliope-sp-purple-dark), var(--calliope-sp-purple) 72%, var(--calliope-sp-pink));
  color: #fff;
  box-shadow: 0 8px 18px rgba(114, 24, 203, 0.18);
}

.calliope-sp-wrap .button.button-primary:hover,
.calliope-sp-wrap .button.button-primary.calliope-sp-cta:hover,
.calliope-sp-wrap .button.button-secondary.calliope-sp-dark:hover {
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(114, 24, 203, 0.24);
}

.calliope-sp-wrap .button.button-secondary {
  background: #fff;
  border-color: var(--calliope-sp-border-strong);
  color: var(--calliope-sp-heading);
}

.calliope-sp-wrap .button.button-secondary:hover {
  border-color: rgba(114, 24, 203, 0.55);
  color: var(--calliope-sp-purple);
}

.calliope-sp-wrap .button.button-link-delete {
  height: auto;
  padding: 5px 10px;
  border: 1px solid #f0b8b2;
  border-radius: var(--calliope-sp-radius);
  background: var(--calliope-sp-danger-soft);
  color: var(--calliope-sp-danger);
  line-height: 1.4;
  text-decoration: none;
}

.calliope-sp-wrap .button.button-link-delete:hover {
  border-color: #e68c84;
  background: #ffe7e4;
  color: #991b1b;
}

.calliope-sp-wrap .button:focus {
  border-color: var(--calliope-sp-purple) !important;
  box-shadow: var(--calliope-sp-focus) !important;
  outline: none;
}

/* Network tabs */
.calliope-sp-wrap .calliope-sp-net-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 4px 0 0;
}

.calliope-sp-wrap .calliope-sp-net-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 11px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  background: #fff;
  color: var(--calliope-sp-heading);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, color 0.16s ease, transform 0.16s ease;
}

.calliope-sp-wrap .calliope-sp-net-tab:hover {
  transform: translateY(-1px);
  border-color: var(--calliope-sp-border-strong);
  color: var(--calliope-sp-purple);
}

.calliope-sp-wrap .calliope-sp-net-tab.is-active {
  box-shadow: var(--calliope-sp-shadow-soft);
}

.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected {
  color: #7a8495;
  background: var(--calliope-sp-surface-soft);
}

.calliope-sp-wrap .calliope-sp-net-tab.is-connected {
  color: var(--calliope-sp-net-color, var(--calliope-sp-heading));
  border-color: currentColor;
}

.calliope-sp-wrap .calliope-sp-net-tab.net-bluesky.is-connected { --calliope-sp-net-color: #1185fe; }
.calliope-sp-wrap .calliope-sp-net-tab.net-mastodon.is-connected { --calliope-sp-net-color: #6364ff; }
.calliope-sp-wrap .calliope-sp-net-tab.net-tumblr.is-connected { --calliope-sp-net-color: #001935; }
.calliope-sp-wrap .calliope-sp-net-tab.net-pinterest.is-connected { --calliope-sp-net-color: #e60023; }
.calliope-sp-wrap .calliope-sp-net-tab.net-threads.is-connected { --calliope-sp-net-color: #111111; }
.calliope-sp-wrap .calliope-sp-net-tab.net-instagram.is-connected { --calliope-sp-net-color: #d62976; }
.calliope-sp-wrap .calliope-sp-net-tab.net-linkedin.is-connected { --calliope-sp-net-color: #0a66c2; }
.calliope-sp-wrap .calliope-sp-net-tab.net-blogger.is-connected { --calliope-sp-net-color: #f57d00; }
.calliope-sp-wrap .calliope-sp-net-tab.net-telegram.is-connected { --calliope-sp-net-color: #229ed9; }
.calliope-sp-wrap .calliope-sp-net-tab.net-facebook.is-connected { --calliope-sp-net-color: #1877f2; }

.calliope-sp-wrap .calliope-sp-net-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  display: inline-block;
  color: currentColor;
  overflow: hidden;
}

.calliope-sp-wrap .calliope-sp-net-tab .calliope-sp-network-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  color: currentColor;
  overflow: hidden;
}

.calliope-sp-wrap .calliope-sp-net-tab .calliope-sp-network-icon svg {
  display: block;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}

.calliope-sp-wrap .calliope-sp-net-icon--threads path {
  fill: currentColor;
}

/* Connections layout */
.calliope-sp-wrap .calliope-sp-connection-shell {
  display: grid;
  gap: 16px;
  margin-top: 0;
}

.calliope-sp-wrap .calliope-sp-connection-shell.calliope-sp-card {
  max-width: none;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.calliope-sp-wrap .calliope-spp-integrated-admin.calliope-sp-connection-shell {
  max-width: none;
}

.calliope-sp-wrap .calliope-sp-connection-heading,
.calliope-sp-wrap .calliope-spp-network-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.calliope-sp-wrap .calliope-sp-connection-heading > div,
.calliope-sp-wrap .calliope-spp-network-heading > div {
  min-width: 0;
}

.calliope-sp-wrap .calliope-sp-connection-heading h2,
.calliope-sp-wrap .calliope-spp-network-heading h2 {
  margin: 0;
  color: var(--calliope-sp-heading);
  font-size: 18px;
  line-height: 1.25;
}

.calliope-sp-wrap .calliope-sp-connection-heading p,
.calliope-sp-wrap .calliope-spp-network-heading p {
  margin: 3px 0 0;
  color: var(--calliope-sp-muted);
  line-height: 1.45;
}

.calliope-sp-wrap .calliope-sp-connection-logo,
.calliope-sp-wrap .calliope-spp-network-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  overflow: hidden;
  border: 1px solid currentColor;
  border-radius: 8px;
  background: #fff;
  color: var(--calliope-sp-net-color, var(--calliope-network-color, var(--calliope-sp-heading)));
  box-shadow: var(--calliope-sp-shadow-soft);
}

.calliope-sp-wrap .calliope-sp-connection-shell.is-disconnected .calliope-sp-connection-logo {
  color: #697386;
}

.calliope-sp-wrap .calliope-sp-connection-shell.is-disconnected .calliope-sp-connection-logo svg:not([fill="none"]),
.calliope-sp-wrap .calliope-sp-connection-shell.is-disconnected .calliope-sp-connection-logo svg :not([fill="none"]) {
  fill: currentColor !important;
}

.calliope-sp-wrap .calliope-sp-connection-shell.is-disconnected .calliope-sp-connection-logo svg[stroke]:not([stroke="none"]),
.calliope-sp-wrap .calliope-sp-connection-shell.is-disconnected .calliope-sp-connection-logo svg [stroke]:not([stroke="none"]) {
  stroke: currentColor !important;
}

.calliope-sp-wrap .calliope-sp-connection-logo svg,
.calliope-sp-wrap .calliope-sp-connection-logo .calliope-sp-net-icon,
.calliope-sp-wrap .calliope-sp-connection-logo .calliope-sp-network-icon svg,
.calliope-sp-wrap .calliope-spp-network-mark svg {
  display: block;
  width: 28px;
  height: 28px;
  max-width: 28px;
  max-height: 28px;
}

.calliope-sp-wrap .calliope-sp-connection-grid,
.calliope-sp-wrap .calliope-spp-discord-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, .85fr);
  gap: 18px;
  align-items: stretch;
}

.calliope-sp-wrap .calliope-sp-connection-grid > *,
.calliope-sp-wrap .calliope-spp-discord-grid > * {
  min-width: 0;
  height: 100%;
}

.calliope-sp-wrap .calliope-sp-connection-main-card,
.calliope-sp-wrap .calliope-sp-connection-guide,
.calliope-sp-wrap .calliope-spp-network-card {
  margin: 0;
}

.calliope-sp-wrap .calliope-sp-connection-main-card {
  max-width: none;
  height: 100%;
  box-shadow: none;
}

.calliope-sp-wrap .calliope-sp-connection-main-card > h3:first-child,
.calliope-sp-wrap .calliope-sp-connection-main > h3:first-child {
  margin-top: 0;
}

.calliope-sp-wrap .calliope-sp-connection-card-heading {
  align-items: flex-start;
  margin-bottom: 14px;
}

.calliope-sp-wrap .calliope-sp-connection-card-heading h2,
.calliope-sp-wrap .calliope-sp-connection-card-heading h3 {
  margin: 0;
}

.calliope-sp-wrap .calliope-sp-connection-guide,
.calliope-sp-wrap .calliope-spp-discord-grid > .calliope-spp-setup-guide {
  display: flex;
  flex-direction: column;
  margin-top: 0;
}

.calliope-sp-wrap .calliope-sp-connection-guide .calliope-sp-howto,
.calliope-sp-wrap .calliope-sp-connection-guide .calliope-sp-hint,
.calliope-sp-wrap .calliope-sp-connection-guide .calliope-sp-hint-box,
.calliope-sp-wrap .calliope-sp-connection-guide .calliope-spp-setup-guide {
  margin: 0 0 14px;
  padding: 0;
  border: 0;
  background: transparent;
}

.calliope-sp-wrap .calliope-sp-connection-guide .calliope-sp-howto:last-child,
.calliope-sp-wrap .calliope-sp-connection-guide .calliope-sp-hint:last-child,
.calliope-sp-wrap .calliope-sp-connection-guide .calliope-sp-hint-box:last-child,
.calliope-sp-wrap .calliope-sp-connection-guide .calliope-spp-setup-guide:last-child {
  margin-bottom: 0;
}

.calliope-sp-wrap .calliope-sp-connection-guide h3,
.calliope-sp-wrap .calliope-sp-connection-guide > .calliope-sp-howto > b:first-child,
.calliope-sp-wrap .calliope-sp-connection-guide > .calliope-sp-hint > b:first-child,
.calliope-sp-wrap .calliope-spp-setup-guide h3 {
  display: block;
  margin: 0 0 14px;
  color: var(--calliope-sp-heading);
  font-size: 15px;
  line-height: 1.3;
  font-weight: 700;
}

.calliope-sp-wrap .calliope-sp-connection-guide ol,
.calliope-sp-wrap .calliope-spp-setup-guide ol,
.calliope-sp-wrap .calliope-sp-connection-steps {
  margin: 16px 0 0;
  padding: 0;
  counter-reset: calliope-connection-step;
  list-style: none;
}

.calliope-sp-wrap .calliope-sp-connection-guide ol li,
.calliope-sp-wrap .calliope-spp-setup-guide ol li,
.calliope-sp-wrap .calliope-sp-connection-steps li {
  position: relative;
  margin: 0 0 15px;
  padding-left: 38px;
  counter-increment: calliope-connection-step;
}

.calliope-sp-wrap .calliope-sp-connection-guide ol li:last-child,
.calliope-sp-wrap .calliope-spp-setup-guide ol li:last-child,
.calliope-sp-wrap .calliope-sp-connection-steps li:last-child {
  margin-bottom: 0;
}

.calliope-sp-wrap .calliope-sp-connection-guide ol li::before,
.calliope-sp-wrap .calliope-spp-setup-guide ol li::before,
.calliope-sp-wrap .calliope-sp-connection-steps li::before {
  content: counter(calliope-connection-step);
  position: absolute;
  left: 0;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--calliope-sp-purple);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}

.calliope-sp-wrap .calliope-sp-connection-guide li strong,
.calliope-sp-wrap .calliope-sp-connection-guide li span,
.calliope-sp-wrap .calliope-spp-setup-guide li strong,
.calliope-sp-wrap .calliope-spp-setup-guide li span {
  display: block;
}

.calliope-sp-wrap .calliope-sp-connection-guide li span,
.calliope-sp-wrap .calliope-spp-setup-guide li span {
  margin-top: 3px;
  color: var(--calliope-sp-muted);
  line-height: 1.45;
}

.calliope-sp-wrap .calliope-sp-connection-resource-link {
  margin: auto 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--calliope-sp-border);
}

.calliope-sp-wrap .calliope-sp-connection-resource-link a {
  display: inline-flex;
  align-items: center;
  color: var(--calliope-sp-purple);
  font-weight: 700;
  text-decoration: none;
}

.calliope-sp-wrap .calliope-sp-connection-resource-link a:hover,
.calliope-sp-wrap .calliope-sp-connection-resource-link a:focus {
  color: var(--calliope-sp-purple-dark);
  text-decoration: underline;
}

@media (max-width: 1100px) {
  .calliope-sp-wrap .calliope-sp-connection-grid,
  .calliope-sp-wrap .calliope-spp-discord-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .calliope-sp-wrap .calliope-sp-connection-heading,
  .calliope-sp-wrap .calliope-spp-network-heading {
    align-items: flex-start;
  }
}

/* Badges and option chips */
.calliope-sp-wrap .calliope-sp-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  max-width: 180px;
  padding: 5px 12px;
  border: 0;
  border-radius: 999px;
  background: #f1f3f5;
  color: var(--calliope-sp-muted);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.35;
  text-align: center;
  white-space: normal;
}

.calliope-sp-wrap .calliope-sp-badge .dot {
  display: none;
}

.calliope-sp-wrap .calliope-sp-badge.is-ok {
  background: #e9f8ee;
  color: #087443;
}

.calliope-sp-wrap .calliope-sp-badge.is-warn {
  background: #fff5da;
  color: #8a5a00;
}

.calliope-sp-wrap .calliope-sp-badge.is-bad {
  background: #f1f3f5;
  color: #667085;
}

.calliope-sp-wrap .calliope-sp-checks {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 6px;
}

.calliope-sp-wrap .calliope-sp-checks label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  padding: 8px 10px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  background: #fff;
  color: var(--calliope-sp-heading);
  font-size: 13px;
}

.calliope-sp-wrap .calliope-sp-checks input {
  margin: 0;
}

/* Help blocks */
.calliope-sp-wrap .calliope-sp-help,
.calliope-sp-wrap .calliope-sp-howto,
.calliope-sp-wrap .calliope-sp-hint-box {
  margin: 0 0 14px;
  padding: 12px 13px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  background: var(--calliope-sp-surface-soft);
  color: #475467;
}

.calliope-sp-wrap .calliope-sp-howto.calliope-sp-howto--below {
  margin-top: 12px;
}

.calliope-sp-wrap .calliope-sp-help .dashicons {
  color: var(--calliope-sp-purple);
  vertical-align: middle;
  margin-right: 4px;
}

.calliope-sp-wrap .calliope-sp-howto b,
.calliope-sp-wrap .calliope-sp-help b {
  color: var(--calliope-sp-heading);
}

.calliope-sp-wrap .calliope-sp-guide-list,
.calliope-sp-wrap .calliope-sp-steps {
  margin: 8px 0 0 18px;
  padding: 0;
}

.calliope-sp-wrap .calliope-sp-guide-list li,
.calliope-sp-wrap .calliope-sp-steps li {
  margin: 0 0 7px;
}

.calliope-sp-wrap .calliope-sp-steps--compact li {
  margin-bottom: 5px;
}

/* Image editor */
.calliope-sp-wrap #edit-area {
  margin-top: 10px;
  padding: 14px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  background: var(--calliope-sp-surface-soft);
}

.calliope-sp-wrap .cropper-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(100%, 360px);
  aspect-ratio: 4 / 5;
  min-height: 0;
  margin: 0 auto;
  overflow: hidden;
  cursor: grab;
  touch-action: none;
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  background: #eef3fb;
}

.calliope-sp-wrap .cropper-wrapper.is-dragging {
  cursor: grabbing;
}

.calliope-sp-wrap .cropper-wrapper img {
  display: none;
}

.calliope-sp-wrap .cropper-wrapper canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.calliope-sp-wrap .calliope-sp-native-crop-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.calliope-sp-wrap .calliope-sp-native-crop-controls label {
  margin: 0;
}

.calliope-sp-wrap .calliope-sp-native-crop-controls input[type="range"] {
  width: min(100%, 220px);
}

.calliope-sp-wrap .calliope-sp-crop-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 14px;
  padding-top: 8px;
}

.calliope-sp-wrap #preview {
  margin-top: 12px;
}

.calliope-sp-wrap #preview img {
  width: min(100%, 280px);
  max-width: 100%;
  height: auto;
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  background: #fff;
}

/* Tables */
.calliope-sp-wrap table.widefat {
  table-layout: fixed;
  width: 100%;
  border-color: var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  overflow: hidden;
}

.calliope-sp-wrap table.widefat th,
.calliope-sp-wrap table.widefat td {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.calliope-sp-wrap table.widefat th:nth-child(1),
.calliope-sp-wrap table.widefat td:nth-child(1) {
  width: 140px;
}

.calliope-sp-wrap table.widefat th:nth-child(2),
.calliope-sp-wrap table.widefat td:nth-child(2) {
  width: 110px;
}

.calliope-sp-wrap table.widefat th:nth-child(3),
.calliope-sp-wrap table.widefat td:nth-child(3) {
  width: 90px;
}

/* Review footer */
.calliope-sp-wrap .calliope-sp-review-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  max-width: 1180px;
  margin: 16px auto 0;
  padding: 14px 16px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  background: #fff;
  box-shadow: var(--calliope-sp-shadow-soft);
}

.calliope-sp-wrap .calliope-sp-review-box__text {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
  min-width: 0;
  color: var(--calliope-sp-muted);
  font-size: 12.5px;
  line-height: 1.4;
}
.calliope-sp-wrap .calliope-sp-review-box__text strong {
  flex: 0 0 auto;
  white-space: nowrap;
}
.calliope-sp-wrap .calliope-sp-review-box__text span {
  min-width: 0;
}
@media (max-width: 900px) {
  .calliope-sp-wrap .calliope-sp-review-box__text {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }
  .calliope-sp-wrap .calliope-sp-review-box__text strong { white-space: normal; }
}

.calliope-sp-wrap .calliope-sp-review-box__text strong {
  color: var(--calliope-sp-heading);
}

.calliope-sp-wrap .calliope-sp-review-box__actions {
  flex: 0 0 auto;
}

/* Browser publication progress panel */
#wpbody-content .calliope-sp-job-runner-notice {
  border-left-color: var(--calliope-sp-purple, #7218cb);
  padding: 0;
  overflow: hidden;
}

#wpbody-content .calliope-sp-job-runner-notice .notice-dismiss {
  top: 10px;
}

#wpbody-content .calliope-sp-job-progress {
  padding: 16px 18px 18px;
  background: linear-gradient(135deg, #ffffff 0%, #f5fbff 100%);
}

#wpbody-content .calliope-sp-job-progress__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 8px;
}

#wpbody-content .calliope-sp-job-progress__title {
  color: #1f2a44;
  font-size: 16px;
  line-height: 1.3;
  font-weight: 700;
}

#wpbody-content .calliope-sp-job-progress__percent {
  min-width: 58px;
  padding: 5px 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, #7218cb, #f23dc5);
  color: #fff;
  font-weight: 700;
  text-align: center;
}

#wpbody-content .calliope-sp-job-progress__status {
  margin: 0 0 11px;
  color: #475467;
  font-size: 14px;
  font-weight: 700;
}

#wpbody-content .calliope-sp-job-progress__bar {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #dce9f6;
}

#wpbody-content .calliope-sp-job-progress__bar-fill {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #7218cb 0%, #8f2fda 58%, #f23dc5 100%);
  transition: width 0.35s ease;
}

#wpbody-content .calliope-sp-job-progress__meta,
#wpbody-content .calliope-sp-job-progress__help {
  margin: 9px 0 0;
  color: #667085;
  font-size: 12px;
}

#wpbody-content .calliope-sp-job-progress__networks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 0;
}

#wpbody-content .calliope-sp-job-progress__chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 9px;
  border: 1px solid #d8e0ee;
  border-radius: 999px;
  background: #fff;
  color: #667085;
  font-size: 12px;
  line-height: 1;
}

#wpbody-content .calliope-sp-job-progress__chip strong {
  font-weight: 700;
}

#wpbody-content .calliope-sp-job-progress__chip em {
  color: #98a2b3;
  font-style: normal;
  font-weight: 900;
}

#wpbody-content .calliope-sp-job-progress__chip.is-current {
  border-color: #ddc7f5;
  background: #fbf4ff;
  color: #56149d;
}

#wpbody-content .calliope-sp-job-progress__chip.is-current em {
  color: #7218cb;
}

#wpbody-content .calliope-sp-job-progress__chip.is-complete {
  border-color: #abefc6;
  background: #ecfdf3;
  color: #067647;
}

#wpbody-content .calliope-sp-job-progress__chip.is-complete em {
  color: #12b76a;
}

#wpbody-content .calliope-sp-job-progress__chip.is-warning {
  border-color: #fedf89;
  background: #fffaeb;
  color: #93370d;
}

#wpbody-content .calliope-sp-job-progress__chip.is-warning em {
  color: #b54708;
}

#wpbody-content .calliope-sp-job-progress__chip.is-error {
  border-color: #fecdca;
  background: #fef3f2;
  color: #b42318;
}

#wpbody-content .calliope-sp-job-progress__chip.is-error em {
  color: #d92d20;
}

#wpbody-content {
  padding-bottom: 32px !important;
}

#wpfooter {
  position: relative !important;
  clear: both;
  z-index: 0;
}

@media (max-width: 1080px) {
  .calliope-sp-wrap .calliope-sp-grid {
    grid-template-columns: 1fr;
  }

  .calliope-sp-wrap .calliope-sp-publication-type-layout {
    width: 100%;
    max-width: none;
  }

  .calliope-sp-wrap .calliope-sp-topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .calliope-sp-wrap .calliope-sp-topbar__actions {
    justify-content: flex-start;
  }
}

@media (max-width: 782px) {
  .calliope-sp-wrap .calliope-sp-topbar {
    padding: 14px;
  }

  .calliope-sp-wrap .calliope-sp-topbar__brand {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .calliope-sp-wrap .calliope-sp-topbar__logo-clean {
    width: min(165px, 78vw);
  }

  .calliope-sp-wrap .calliope-sp-topbar__copy {
    padding-left: 0;
    border-left: 0;
  }

  .calliope-sp-wrap .nav-tab-wrapper {
    flex-wrap: wrap;
    align-items: stretch;
    border-bottom: 1px solid var(--calliope-sp-border);
    padding-bottom: 7px;
  }

  .calliope-sp-wrap .nav-tab {
    flex: 0 0 auto;
    min-height: 40px;
    margin: 0;
    border-radius: var(--calliope-sp-radius);
  }

  .calliope-sp-wrap .calliope-sp-card {
    padding: 15px;
  }

  .calliope-sp-wrap .calliope-sp-review-box {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* AI composer and settings additions */
.calliope-sp-wrap .calliope-sp-field-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.calliope-sp-wrap .calliope-sp-field-head label {
  margin: 0;
}

.calliope-sp-wrap .calliope-sp-ai-btn {
  min-height: 28px;
  padding: 0 10px;
  border-color: #d8c8f1;
  color: var(--calliope-sp-purple);
  font-size: 12px;
  font-weight: 700;
}

.calliope-sp-wrap .calliope-sp-ai-settings-link {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: -4px 0 16px;
  color: var(--calliope-sp-muted);
  font-size: 12px;
  line-height: 1.45;
}

.calliope-sp-wrap .calliope-sp-ai-settings-link a {
  color: var(--calliope-sp-purple);
  font-weight: 700;
  text-decoration: none;
}

.calliope-sp-wrap .calliope-sp-ai-settings-link a:hover,
.calliope-sp-wrap .calliope-sp-ai-settings-link a:focus {
  color: var(--calliope-sp-purple-dark);
  text-decoration: underline;
}

.calliope-sp-wrap .calliope-sp-ai-complete {
  margin-top: 14px;
}

.calliope-sp-wrap .calliope-sp-ai-complete-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 36px;
  padding-right: 34px;
  text-align: center;
  white-space: normal;
}

.calliope-sp-wrap .button.button-primary.calliope-sp-ai-complete-btn {
  border-color: transparent;
  color: #fff;
  font-size: 13px;
}

.calliope-sp-wrap .button.button-primary.calliope-sp-ai-complete-btn:hover,
.calliope-sp-wrap .button.button-primary.calliope-sp-ai-complete-btn:focus {
  color: #fff;
}

.calliope-sp-wrap .calliope-sp-ai-complete-btn[aria-busy="true"]::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 12px;
  width: 14px;
  height: 14px;
  margin-top: -7px;
  border: 2px solid rgba(255, 255, 255, 0.55);
  border-top-color: #fff;
  border-radius: 50%;
  animation: calliope-sp-ai-spin 0.75s linear infinite;
}

@keyframes calliope-sp-ai-spin {
  to {
    transform: rotate(360deg);
  }
}

.calliope-sp-wrap .calliope-sp-ai-btn:hover,
.calliope-sp-wrap .calliope-sp-ai-btn:focus {
  border-color: var(--calliope-sp-purple);
  color: var(--calliope-sp-purple-dark);
  box-shadow: var(--calliope-sp-focus);
}

.calliope-sp-wrap .calliope-sp-ai-btn[disabled],
.calliope-sp-wrap .calliope-sp-ai-btn[aria-disabled="true"] {
  border-color: #d0d5dd;
  background: #f2f4f7;
  color: #98a2b3;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

.calliope-sp-wrap .calliope-sp-ai-btn[disabled]:hover,
.calliope-sp-wrap .calliope-sp-ai-btn[aria-disabled="true"]:hover,
.calliope-sp-wrap .calliope-sp-ai-btn[disabled]:focus,
.calliope-sp-wrap .calliope-sp-ai-btn[aria-disabled="true"]:focus {
  border-color: #d0d5dd;
  color: #98a2b3;
  box-shadow: none;
}

.calliope-sp-wrap .calliope-sp-ai-status {
  min-height: 18px;
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.4;
}

.calliope-sp-wrap .calliope-sp-ai-status.is-error {
  color: var(--calliope-sp-danger);
}

.calliope-sp-wrap .calliope-sp-ai-status.is-loading {
  color: var(--calliope-sp-muted);
}

.calliope-sp-wrap .calliope-sp-settings-grid,
.calliope-sp-wrap .calliope-sp-doc-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
}

.calliope-sp-wrap .calliope-sp-doc-grid {
  align-items: stretch;
}

.calliope-sp-wrap .calliope-sp-settings-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: linear-gradient(180deg, #ffffff 0%, #fbf8ff 100%);
  border-color: #dfd2f4;
}

.calliope-sp-wrap .calliope-sp-settings-hero h3 {
  margin-bottom: 8px;
  font-size: 20px;
}

.calliope-sp-wrap .calliope-sp-settings-hero p {
  max-width: 820px;
  margin: 0;
  color: var(--calliope-sp-text);
  line-height: 1.55;
}

.calliope-sp-wrap .calliope-sp-settings-hero__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  min-width: 230px;
}

.calliope-sp-wrap .calliope-sp-settings-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
}


.calliope-sp-wrap .calliope-sp-settings-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.calliope-sp-wrap .calliope-sp-settings-card__head h3 {
  margin-bottom: 6px;
}

.calliope-sp-wrap .calliope-sp-settings-card__head p {
  margin: 0;
  color: var(--calliope-sp-muted);
  line-height: 1.5;
}

.calliope-sp-wrap .calliope-sp-settings-status {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #f1f3f5;
  color: #596274;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.2;
}

.calliope-sp-wrap .calliope-sp-settings-status.is-ok {
  background: #e9f8ee;
  color: #087443;
}

.calliope-sp-wrap .calliope-sp-settings-status.is-warn {
  background: #fff5da;
  color: #8a5a00;
}

.calliope-sp-wrap .calliope-sp-settings-status.is-neutral {
  background: #eef2f7;
  color: #536079;
}

.calliope-sp-wrap .calliope-sp-settings-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.calliope-sp-wrap .calliope-sp-settings-summary div,
.calliope-sp-wrap .calliope-sp-settings-note,
.calliope-sp-wrap .calliope-sp-settings-map a {
  border: 1px solid var(--calliope-sp-border);
  border-radius: 8px;
  background: #f8f9fb;
}

.calliope-sp-wrap .calliope-sp-settings-summary div {
  padding: 10px 12px;
}

.calliope-sp-wrap .calliope-sp-settings-summary strong,
.calliope-sp-wrap .calliope-sp-settings-note strong,
.calliope-sp-wrap .calliope-sp-settings-map strong {
  display: block;
  margin-bottom: 4px;
  color: var(--calliope-sp-heading);
  font-size: 12px;
  font-weight: 800;
}

.calliope-sp-wrap .calliope-sp-settings-summary span,
.calliope-sp-wrap .calliope-sp-settings-note span,
.calliope-sp-wrap .calliope-sp-settings-map span {
  display: block;
  color: var(--calliope-sp-muted);
  font-size: 12px;
  line-height: 1.4;
}

.calliope-sp-wrap .calliope-sp-settings-form {
  display: grid;
  gap: 14px;
}

.calliope-sp-wrap .calliope-sp-settings-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.calliope-sp-wrap .calliope-sp-settings-actions {
  margin-top: 0;
}

.calliope-sp-wrap .calliope-sp-settings-clear-key {
  margin-top: 0;
}

.calliope-sp-wrap .calliope-sp-settings-map {
  display: grid;
  gap: 10px;
}

.calliope-sp-wrap .calliope-sp-settings-map a {
  display: block;
  padding: 12px 14px;
  text-decoration: none;
}

.calliope-sp-wrap .calliope-sp-settings-map a:hover,
.calliope-sp-wrap .calliope-sp-settings-map a:focus-visible {
  border-color: var(--calliope-sp-purple);
  box-shadow: var(--calliope-sp-focus);
  outline: none;
}

.calliope-sp-wrap .calliope-sp-settings-note {
  padding: 12px 14px;
  background: #fbf8ff;
  border-color: #dfd2f4;
}

.calliope-sp-wrap .calliope-sp-secret-preview {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  padding: 7px 10px;
  border: 1px solid #d8c8f1;
  border-radius: var(--calliope-sp-radius);
  background: var(--calliope-sp-purple-soft);
  color: var(--calliope-sp-heading);
  font-size: 12.5px;
  line-height: 1.35;
}

.calliope-sp-wrap .calliope-sp-secret-preview code {
  padding: 2px 6px;
  border-radius: 5px;
  background: #fff;
  color: var(--calliope-sp-text);
  font-size: 12px;
}

.calliope-sp-wrap .calliope-sp-doc-list {
  margin: 10px 0 0;
  padding-left: 19px;
  color: var(--calliope-sp-text);
  font-size: 13px;
  line-height: 1.55;
}

.calliope-sp-wrap .calliope-sp-doc-list li {
  margin: 0 0 7px;
}

.calliope-sp-wrap .calliope-sp-settings-wide {
  grid-column: 1 / -1;
}

.calliope-sp-wrap .calliope-sp-inline-check {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 10px;
  color: var(--calliope-sp-text);
  font-size: 13px;
  line-height: 1.45;
}

.calliope-sp-wrap .calliope-sp-inline-check input {
  margin-top: 2px;
}

.calliope-sp-wrap .calliope-sp-doc-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: linear-gradient(180deg, #ffffff 0%, #fbf8ff 100%);
  border-color: #dfd2f4;
}

.calliope-sp-wrap .calliope-sp-doc-hero h3 {
  margin-bottom: 8px;
  font-size: 20px;
}

.calliope-sp-wrap .calliope-sp-doc-hero p {
  max-width: 820px;
  margin: 0;
  color: var(--calliope-sp-text);
  line-height: 1.55;
}

.calliope-sp-wrap .calliope-sp-doc-eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  margin-bottom: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--calliope-sp-purple-soft);
  color: var(--calliope-sp-purple);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.calliope-sp-wrap .calliope-sp-doc-hero__actions,
.calliope-sp-wrap .calliope-sp-doc-card__actions,
.calliope-sp-wrap .calliope-sp-doc-link-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.calliope-sp-wrap .calliope-sp-doc-hero__actions {
  justify-content: flex-end;
  min-width: 250px;
}

.calliope-sp-wrap .calliope-sp-doc-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.calliope-sp-wrap .calliope-sp-doc-card__head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.calliope-sp-wrap .calliope-sp-doc-card__head h3 {
  margin-bottom: 6px;
}

.calliope-sp-wrap .calliope-sp-doc-card__head p {
  margin: 0;
  color: var(--calliope-sp-muted);
  line-height: 1.5;
}

.calliope-sp-wrap .calliope-sp-doc-step {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--calliope-sp-purple), #d728ca);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
}

.calliope-sp-wrap .calliope-sp-doc-network-grid,
.calliope-sp-wrap .calliope-sp-doc-pro-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.calliope-sp-wrap .calliope-sp-doc-network-chip,
.calliope-sp-wrap .calliope-sp-doc-pro-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 8px;
  background: #fff;
  color: var(--calliope-sp-heading);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.calliope-sp-wrap .calliope-sp-doc-network-chip:hover,
.calliope-sp-wrap .calliope-sp-doc-network-chip:focus-visible {
  border-color: var(--calliope-sp-purple);
  color: var(--calliope-sp-purple);
  box-shadow: var(--calliope-sp-focus);
  outline: none;
}

.calliope-sp-wrap .calliope-sp-doc-network-chip .calliope-sp-net-icon,
.calliope-sp-wrap .calliope-sp-doc-network-chip svg {
  width: 18px;
  height: 18px;
  color: #8b95a3;
  filter: grayscale(1) saturate(0);
}

.calliope-sp-wrap .calliope-sp-doc-pro-chip {
  background: #f8f9fb;
  color: #4d5664;
}

.calliope-sp-wrap .calliope-sp-doc-checklist {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.calliope-sp-wrap .calliope-sp-doc-checklist li {
  position: relative;
  padding-left: 20px;
  color: var(--calliope-sp-text);
  font-size: 13px;
  line-height: 1.5;
}

.calliope-sp-wrap .calliope-sp-doc-checklist li::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 2px;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--calliope-sp-purple);
}

.calliope-sp-wrap .calliope-sp-doc-link-row {
  margin-top: auto;
}

.calliope-sp-wrap .calliope-sp-doc-link-row a {
  color: var(--calliope-sp-purple);
  font-weight: 700;
  text-decoration: none;
}

.calliope-sp-wrap .calliope-sp-doc-link-row a:hover,
.calliope-sp-wrap .calliope-sp-doc-link-row a:focus {
  color: var(--calliope-sp-purple-dark);
  text-decoration: underline;
}

.calliope-sp-wrap .calliope-sp-doc-flow {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.calliope-sp-wrap .calliope-sp-doc-flow span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid #dfd2f4;
  border-radius: 8px;
  background: #fbf8ff;
  color: var(--calliope-sp-purple-dark);
  font-size: 13px;
  font-weight: 800;
  text-align: center;
}

@media (min-width: 960px) {
  .calliope-sp-wrap .calliope-sp-settings-grid {
    grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  }

  .calliope-sp-wrap .calliope-sp-doc-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .calliope-sp-wrap .calliope-sp-doc-hero {
    grid-column: 1 / -1;
  }

  .calliope-sp-wrap .calliope-sp-doc-card--wide {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .calliope-sp-wrap .calliope-sp-field-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .calliope-sp-wrap .calliope-sp-doc-hero {
    align-items: flex-start;
    flex-direction: column;
  }

  .calliope-sp-wrap .calliope-sp-settings-hero,
  .calliope-sp-wrap .calliope-sp-settings-card__head {
    align-items: flex-start;
    flex-direction: column;
  }

  .calliope-sp-wrap .calliope-sp-settings-hero__actions {
    justify-content: flex-start;
    min-width: 0;
  }

  .calliope-sp-wrap .calliope-sp-settings-summary,
  .calliope-sp-wrap .calliope-sp-settings-form-grid {
    grid-template-columns: 1fr;
  }

  .calliope-sp-wrap .calliope-sp-doc-hero__actions {
    justify-content: flex-start;
    min-width: 0;
  }

  .calliope-sp-wrap .calliope-sp-doc-flow {
    grid-template-columns: 1fr;
  }
}

.calliope-sp-wrap .calliope-sp-link-search-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.calliope-sp-wrap .calliope-sp-link-search-row input[type="search"] {
  flex: 1 1 auto;
}

.calliope-sp-wrap .calliope-sp-link-search-row .button {
  flex: 0 0 auto;
}

.calliope-sp-wrap .calliope-sp-link-results {
  display: grid;
  gap: 6px;
  max-height: 300px;
  margin-top: 8px;
  padding: 6px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  background: var(--calliope-sp-surface-soft);
  scroll-padding: 6px;
}

.calliope-sp-wrap .calliope-sp-link-results[hidden] {
  display: none !important;
}

.calliope-sp-wrap .calliope-sp-link-results__message {
  padding: 8px 10px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: calc(var(--calliope-sp-radius) - 2px);
  background: #fff;
  color: var(--calliope-sp-muted);
  font-size: 12px;
}

.calliope-sp-wrap .calliope-sp-link-results__message.is-error {
  border-color: #f3c3bd;
  background: var(--calliope-sp-danger-soft);
  color: var(--calliope-sp-danger);
}

.calliope-sp-wrap .calliope-sp-link-result {
  display: grid;
  gap: 3px;
  width: 100%;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: calc(var(--calliope-sp-radius) - 2px);
  background: #fff;
  color: var(--calliope-sp-text);
  line-height: 1.35;
  text-align: left;
  cursor: pointer;
}

.calliope-sp-wrap .calliope-sp-link-result:hover,
.calliope-sp-wrap .calliope-sp-link-result:focus-visible {
  border-color: var(--calliope-sp-purple);
  box-shadow: var(--calliope-sp-focus);
  outline: none;
}

.calliope-sp-wrap .calliope-sp-link-result[aria-selected="true"],
.calliope-sp-wrap .calliope-sp-link-result.is-selected {
  border-color: var(--calliope-sp-purple);
  background: #faf7ff;
}

.calliope-sp-wrap .calliope-sp-link-result strong {
  display: -webkit-box;
  min-width: 0;
  overflow: hidden;
  color: var(--calliope-sp-heading);
  font-size: 13px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.calliope-sp-wrap .calliope-sp-link-result__meta,
.calliope-sp-wrap .calliope-sp-link-result__excerpt {
  min-width: 0;
  color: var(--calliope-sp-muted);
  font-size: 12px;
  line-height: 1.35;
}

.calliope-sp-wrap .calliope-sp-link-result__meta {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calliope-sp-wrap .calliope-sp-link-result__excerpt {
  display: -webkit-box;
  overflow: hidden;
  overflow-wrap: anywhere;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.calliope-sp-wrap .calliope-sp-link-results__more {
  width: 100%;
  margin: 2px 0 0;
}

.calliope-sp-wrap .calliope-sp-selected-context {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 8px;
  padding: 8px 10px;
  border: 1px solid #d8c8ef;
  border-radius: var(--calliope-sp-radius);
  background: #faf7ff;
  color: var(--calliope-sp-heading);
  font-size: 12px;
  line-height: 1.4;
}

.calliope-sp-wrap .calliope-sp-selected-context[hidden] {
  display: none !important;
}

.calliope-sp-wrap .calliope-sp-selected-context > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calliope-sp-wrap .calliope-sp-change-selection {
  flex: 0 0 auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--calliope-sp-purple);
  font-weight: 600;
  cursor: pointer;
}

.calliope-sp-wrap .calliope-sp-change-selection:hover,
.calliope-sp-wrap .calliope-sp-change-selection:focus-visible {
  color: var(--calliope-sp-purple-dark);
  outline: 2px solid var(--calliope-sp-purple);
  outline-offset: 2px;
}

@media (max-width: 640px) {
  .calliope-sp-wrap .calliope-sp-link-search-row {
    align-items: stretch;
    flex-direction: column;
  }

  .calliope-sp-wrap .calliope-sp-link-search-row .button {
    width: 100%;
  }

  .calliope-sp-wrap .calliope-sp-link-results {
    max-height: 240px;
  }

  .calliope-sp-wrap .calliope-sp-selected-context {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* Generic Free/Pro bridge states. */
.calliope-sp-pro-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 18px;
    padding: 1px 6px;
    border-radius: 999px;
    background: #d9dce3;
    color: #3b4351;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .04em;
    line-height: 1;
}
.calliope-sp-pro-destination {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.calliope-sp-pro-destination--locked {
    color: #747b87;
    cursor: pointer;
    opacity: 1;
    text-decoration: none;
}
.calliope-sp-pro-destination--available .calliope-sp-pro-badge,
.calliope-sp-pro-card--available .calliope-sp-pro-badge {
    background: #211c2e;
    color: #fff;
}
.calliope-sp-wrap .calliope-spp-publication-type {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 0 0 18px;
    padding: 0;
    border: 0;
}
.calliope-sp-wrap .calliope-spp-publication-type legend {
    width: 100%;
    margin: 0 0 8px;
    font-weight: 700;
}
.calliope-sp-wrap .calliope-spp-publication-type label,
.calliope-sp-wrap .calliope-spp-publication-type__locked-option {
    display: flex;
    flex: 1 1 calc(50% - 6px);
    box-sizing: border-box;
    gap: 8px;
    min-width: 240px;
    padding: 13px 15px;
    border: 1px solid #dcdcde;
    border-radius: 8px;
    background: #fff;
    color: var(--calliope-sp-heading);
}
.calliope-sp-wrap .calliope-spp-publication-type label {
    align-items: flex-start;
    cursor: pointer;
}
.calliope-sp-wrap .calliope-spp-publication-type label.is-selected {
    border-color: #2271b1;
    box-shadow: 0 0 0 1px #2271b1;
}
.calliope-sp-wrap .calliope-spp-publication-type label.is-locked,
.calliope-sp-wrap .calliope-spp-publication-type__locked-option {
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    border-color: #dcdcde;
    background: #f6f7f7;
    color: #747b87;
    cursor: default;
    box-shadow: none;
}
.calliope-sp-wrap .calliope-spp-publication-type label.is-locked input,
.calliope-sp-wrap .calliope-spp-publication-type__locked-option input {
    cursor: not-allowed;
}
.calliope-sp-wrap .calliope-spp-publication-type__locked-content {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    min-width: 0;
}
.calliope-sp-wrap .calliope-spp-publication-type strong {
    line-height: 1.25;
}
.calliope-sp-wrap .calliope-spp-publication-type small {
    display: block;
    margin-top: 3px;
    color: #646970;
}
.calliope-sp-wrap .calliope-spp-publication-type label.is-locked small,
.calliope-sp-wrap .calliope-spp-publication-type__locked-option small {
    color: #747b87;
}
.calliope-sp-wrap .calliope-spp-publication-type__cta-button.button {
    min-height: 42px;
    padding: 0 20px;
    border-color: transparent;
    background: linear-gradient(135deg, var(--calliope-sp-purple), #d728ca);
    color: #fff;
    font-weight: 700;
    box-shadow: 0 8px 18px rgba(124, 31, 209, 0.18);
}
.calliope-sp-wrap .calliope-spp-publication-type__cta-button.button:hover,
.calliope-sp-wrap .calliope-spp-publication-type__cta-button.button:focus {
    border-color: transparent;
    background: linear-gradient(135deg, var(--calliope-sp-purple-dark), #c21eb6);
    color: #fff;
}
.calliope-sp-wrap .calliope-spp-publication-type__actions {
    grid-column: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 86px;
    margin: 27px 0 18px;
}
.calliope-sp-pro-panel {
    margin: 0 0 22px;
    padding: 20px;
    border: 1px solid #dcdcde;
    border-radius: 12px;
    background: #fff;
}
.calliope-sp-pro-panel__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 12px;
}
.calliope-sp-pro-panel__head h3,
.calliope-sp-pro-panel__head p {
    margin: 0;
}
.calliope-sp-pro-panel__head p {
    margin-top: 5px;
    color: #646970;
}
.calliope-sp-pro-grid {
    display: grid;
    align-items: stretch;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 10px;
}
.calliope-sp-pro-card {
    min-height: 0;
    height: 100%;
    padding: 10px 12px;
    border: 1px solid #dcdcde;
    border-radius: 8px;
    background: #f6f7f7;
    color: #646970;
    box-sizing: border-box;
}
.calliope-sp-pro-card--link {
    display: block;
    text-decoration: none;
    cursor: pointer;
    transition: border-color .16s ease, box-shadow .16s ease, background-color .16s ease;
}
.calliope-sp-pro-card--link:hover,
.calliope-sp-pro-card--link:focus-visible {
    border-color: var(--calliope-sp-purple);
    background: #fbf8ff;
    box-shadow: 0 0 0 1px rgba(126, 34, 206, .08);
    outline: none;
}
.calliope-sp-pro-card--link:hover .calliope-sp-pro-card__title strong,
.calliope-sp-pro-card--link:focus-visible .calliope-sp-pro-card__title strong {
    color: var(--calliope-sp-heading);
}
.calliope-sp-pro-card--available {
    border-color: #b6b0c6;
    background: #fff;
    color: #1d2327;
}
.calliope-sp-pro-card__title {
    display: grid;
    grid-template-columns: 20px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    min-width: 0;
    min-height: 44px;
}
.calliope-sp-pro-card__title strong {
    display: block;
    min-width: 0;
    color: #4d5664;
    font-weight: 700;
    font-size: 13px;
    line-height: 1.2;
}
.calliope-sp-pro-card__title .calliope-sp-pro-badge {
    margin-left: 0;
    align-self: start;
}
.calliope-sp-pro-card__icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    color: #8b95a3;
    align-self: center;
}
.calliope-sp-pro-card__icon svg {
    display: block;
    width: 22px;
    height: 22px;
}
.calliope-sp-pro-card p {
    min-height: 36px;
    margin: 9px 0 12px;
}

@media (min-width: 1240px) {
  .calliope-sp-pro-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}

@media (max-width: 1239px) {
  .calliope-sp-pro-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  }
}
.calliope-sp-media-modes {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 0;
    padding-top: 16px;
    border-top: 1px solid #e2e4e7;
}
.calliope-sp-media-mode {
    display: block;
    min-height: 0;
    padding: 10px 12px;
    border: 1px solid #dcdcde;
    border-radius: 8px;
    background: #fff;
}
.calliope-sp-media-mode label {
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr);
    grid-template-areas:
        "radio title"
        ". desc";
    column-gap: 10px;
    row-gap: 3px;
    align-items: start;
    cursor: pointer;
}
.calliope-sp-media-mode input[type="radio"] {
    grid-area: radio;
    margin: 2px 0 0;
}
.calliope-sp-media-mode strong {
    grid-area: title;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    line-height: 1.25;
}
.calliope-sp-media-mode label > span {
    grid-area: desc;
    display: block;
    color: #646970;
    font-size: 12px;
    line-height: 1.35;
}
.calliope-sp-media-mode--locked {
    padding-left: 44px;
    background: #f6f7f7;
    color: #747b87;
    cursor: not-allowed;
}
.calliope-sp-media-mode--locked strong {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    line-height: 1.25;
}
.calliope-sp-media-mode--locked > span {
    margin-top: 3px;
}
.calliope-sp-pro-media-cta {
    margin: 10px 0 0;
}
@media (max-width: 782px) {
    .calliope-sp-pro-panel__head {
        flex-direction: column;
    }
}
.calliope-sp-pro-metadata {
    margin-top: 14px;
    padding: 14px;
    border: 1px solid #dcdcde;
    border-radius: 10px;
    background: #f9f9fb;
}
.calliope-sp-pro-metadata h4 { margin: 0 0 10px; }
.calliope-sp-pro-metadata__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}
.calliope-sp-pro-metadata__grid label {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-weight: 600;
}
.calliope-sp-pro-metadata__grid input,
.calliope-sp-pro-metadata__grid select { width: 100%; }
.calliope-sp-pro-metadata__checks {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 12px;
}
@media (max-width: 782px) {
    .calliope-sp-pro-metadata__grid { grid-template-columns: 1fr; }
}

/* Step 29F: integrated Pro destinations and compact media modes. */
.calliope-sp-wrap .calliope-sp-checks .calliope-sp-pro-destination {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 168px;
}

.calliope-sp-wrap .calliope-sp-pro-destination__label {
  min-width: 0;
  font-weight: 700;
}

.calliope-sp-wrap .calliope-sp-checks .calliope-sp-pro-destination--not-configured {
  border-color: #d5d0df;
  background: #fbfaff;
  color: var(--calliope-sp-heading);
  opacity: 1;
}

.calliope-sp-wrap .calliope-sp-checks .calliope-sp-pro-destination--not-configured input:disabled {
  opacity: .72;
}

.calliope-sp-wrap .calliope-sp-checks .calliope-sp-pro-destination--locked {
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  background: var(--calliope-sp-surface-soft);
  color: #747b87;
  text-decoration: none;
  transition: border-color .18s ease, background-color .18s ease, box-shadow .18s ease, color .18s ease, transform .18s ease;
}

.calliope-sp-wrap .calliope-sp-checks a.calliope-sp-pro-destination--locked:hover,
.calliope-sp-wrap .calliope-sp-checks a.calliope-sp-pro-destination--locked:focus-visible {
  border-color: rgba(114, 24, 203, .58);
  background: #f8f2ff;
  box-shadow: 0 6px 16px rgba(76, 29, 149, .12);
  color: var(--calliope-sp-purple-dark);
  outline: none;
  transform: translateY(-1px);
}

.calliope-sp-wrap .calliope-sp-checks a.calliope-sp-pro-destination--locked:hover .calliope-sp-pro-badge,
.calliope-sp-wrap .calliope-sp-checks a.calliope-sp-pro-destination--locked:focus-visible .calliope-sp-pro-badge {
  background: var(--calliope-sp-purple-dark);
  color: #fff;
}

.calliope-sp-wrap .calliope-sp-net-tab--pro.is-disconnected {
  --calliope-sp-net-color: #697386;
  --calliope-network-color: #697386;
  border-color: #c9ced7;
  background: #f2f4f7;
  color: #697386;
}

.calliope-sp-wrap .calliope-sp-net-tab--pro.is-disconnected:hover {
  border-color: #aeb5c0;
  color: #505968;
}

.calliope-sp-wrap .calliope-sp-net-tab--pro.is-disconnected.is-active {
  border-color: #8f98a7;
  color: #424b59;
  box-shadow: var(--calliope-sp-shadow-soft);
}

.calliope-sp-wrap .calliope-sp-media-modes {
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

.calliope-sp-wrap .calliope-sp-media-mode {
  min-width: 0;
  min-height: 0;
  padding: 10px 12px;
}

.calliope-sp-wrap .calliope-sp-media-mode label {
  min-height: 0;
}

.calliope-sp-wrap .calliope-sp-media-mode strong {
  line-height: 1.25;
}

.calliope-sp-wrap .calliope-sp-network-specific-options[hidden],
.calliope-sp-wrap .calliope-sp-pro-metadata[hidden] {
  display: none !important;
}

.calliope-sp-wrap .calliope-sp-network-specific-options {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--calliope-sp-border);
}

.calliope-sp-wrap .calliope-sp-network-specific-options > h3 {
  margin: 0 0 10px;
}

.calliope-sp-wrap .calliope-spp-integrated-admin {
  margin-top: 14px;
}

.calliope-sp-wrap .calliope-spp-integrated-admin > :first-child {
  margin-top: 0;
}

@media (max-width: 640px) {
  .calliope-sp-wrap .calliope-sp-checks .calliope-sp-pro-destination,
  .calliope-sp-wrap .calliope-sp-checks .calliope-sp-pro-destination--locked {
    width: 100%;
    box-sizing: border-box;
  }
}

/* Composer hotfix: keep the primary publish action with the editorial fields. */
.calliope-sp-wrap .calliope-sp-inline-publish-actions {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--calliope-sp-border);
}

.calliope-sp-wrap .calliope-sp-inline-publish-actions .button-primary {
  min-width: 132px;
}


/* 1.5.1: place destinations below the primary action in the editorial column. */
.calliope-sp-wrap .calliope-sp-inline-destinations {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--calliope-sp-border);
}

.calliope-sp-wrap .calliope-sp-inline-destinations > h3 {
  margin-top: 0;
}

.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-checks {
  gap: 9px;
}

.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-hint {
  margin-top: 12px;
}

/* Step 33A visual hotfix: keep every standard destination aligned and readable. */
.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-checks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
  align-items: stretch;
  gap: 10px;
}

.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-checks > label,
.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-checks > a,
.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-checks > span {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  box-sizing: border-box;
  justify-content: flex-start;
  line-height: 1.25;
}

.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-checks > label {
  font-weight: 600;
}

.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-checks input[type="checkbox"] {
  flex: 0 0 auto;
}

.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-pro-destination {
  min-width: 0;
}

.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-pro-destination__label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  font-weight: 600;
  line-height: 1.25;
}

.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-network-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  color: var(--calliope-network-color, currentColor);
}

.calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-network-icon svg {
  display: block;
  width: 18px;
  height: 18px;
}

@media (max-width: 782px) {
  .calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-checks {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .calliope-sp-wrap .calliope-sp-inline-destinations .calliope-sp-checks {
    grid-template-columns: 1fr;
  }
}


/* Free connection tabs keep muted styling when disconnected. */
.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected:not(.calliope-sp-net-tab--pro),
.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected:not(.calliope-sp-net-tab--pro):hover,
.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected:not(.calliope-sp-net-tab--pro):focus,
.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected:not(.calliope-sp-net-tab--pro).is-active {
  --calliope-sp-net-color: #697386;
  border-color: #c9ced7;
  background: #f2f4f7;
  color: #697386;
}
.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected:not(.calliope-sp-net-tab--pro):hover {
  transform: translateY(-1px);
  border-color: #aeb5c0;
  color: #505968;
}
.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected:not(.calliope-sp-net-tab--pro).is-active {
  border-color: #8f98a7;
  color: #424b59;
  box-shadow: var(--calliope-sp-shadow-soft);
}
.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected .calliope-sp-net-icon,
.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected .calliope-sp-network-icon {
  color: currentColor !important;
}

.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected svg:not([fill="none"]),
.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected svg :not([fill="none"]) {
  fill: currentColor !important;
}

.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected svg[stroke]:not([stroke="none"]),
.calliope-sp-wrap .calliope-sp-net-tab.is-disconnected svg [stroke]:not([stroke="none"]) {
  stroke: currentColor !important;
}

@media (max-width: 782px) {
  .calliope-sp-wrap .calliope-sp-publication-type-layout { grid-template-columns: 1fr; gap: 10px; }
  .calliope-sp-wrap .calliope-sp-publication-type-layout > .calliope-spp-publication-type,
  .calliope-sp-wrap .calliope-spp-publication-type__actions { grid-column: 1; }
  .calliope-sp-wrap .calliope-spp-publication-type__actions { justify-content: flex-start; min-height: 0; margin: -6px 0 18px; }
  .calliope-sp-wrap .calliope-spp-publication-type { display: grid; grid-template-columns: 1fr; }
  .calliope-sp-wrap .calliope-spp-publication-type label,
  .calliope-sp-wrap .calliope-spp-publication-type__locked-option { width: 100%; min-width: 0; }
}

/* Step 1: standalone persistent publication History tab. */
.calliope-sp-wrap .calliope-sp-history-overview {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(280px, .85fr);
  gap: 18px;
  margin: 0 0 20px;
}
.calliope-sp-wrap .calliope-sp-history-card,
.calliope-sp-wrap .calliope-sp-history-pro-card {
  min-width: 0;
}
.calliope-sp-wrap .calliope-sp-history-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}
.calliope-sp-wrap .calliope-sp-history-card__head h3 {
  margin-top: 4px;
  margin-bottom: 0;
  font-size: 17px;
}
.calliope-sp-wrap .calliope-sp-history-eyebrow {
  color: var(--calliope-sp-purple);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.calliope-sp-wrap .calliope-sp-history-state,
.calliope-sp-wrap .calliope-sp-history-coming,
.calliope-sp-wrap .calliope-sp-history-pro-owned {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
}
.calliope-sp-wrap .calliope-sp-history-state.is-active {
  background: #edf8f0;
  color: #166534;
}
.calliope-sp-wrap .calliope-sp-history-state.is-warning {
  background: #fff7e6;
  color: #92400e;
}
.calliope-sp-wrap .calliope-sp-history-intro,
.calliope-sp-wrap .calliope-sp-history-pro-card > p {
  margin: 12px 0 0;
  color: var(--calliope-sp-muted);
  line-height: 1.55;
}
.calliope-sp-wrap .calliope-sp-history-metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}
.calliope-sp-wrap .calliope-sp-history-metric {
  padding: 12px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 8px;
  background: #fbfbfc;
}
.calliope-sp-wrap .calliope-sp-history-metric strong,
.calliope-sp-wrap .calliope-sp-history-metric span {
  display: block;
}
.calliope-sp-wrap .calliope-sp-history-metric strong {
  color: var(--calliope-sp-heading);
  font-size: 21px;
  line-height: 1.15;
}
.calliope-sp-wrap .calliope-sp-history-metric span {
  margin-top: 4px;
  color: var(--calliope-sp-muted);
  font-size: 11px;
  line-height: 1.3;
}
.calliope-sp-wrap .calliope-sp-history-metric.is-success strong { color: #166534; }
.calliope-sp-wrap .calliope-sp-history-metric.is-failed strong { color: #b42318; }
.calliope-sp-wrap .calliope-sp-history-metric.is-pending strong { color: #8a5a00; }

.calliope-sp-wrap .calliope-sp-history-card--compact .calliope-sp-history-foot {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #eef0f3;
}

.calliope-sp-wrap .calliope-sp-history-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 6px 16px;
  margin-top: 13px;
  color: var(--calliope-sp-muted);
  font-size: 11px;
}
.calliope-sp-wrap .calliope-sp-history-pro-card {
  position: relative;
  border-style: dashed;
  background: #f4f5f7;
  box-shadow: none;
  color: #6b7280;
}
.calliope-sp-wrap .calliope-sp-history-pro-card h3,
.calliope-sp-wrap .calliope-sp-history-pro-card .calliope-sp-history-eyebrow {
  color: #5f6672;
}
.calliope-sp-wrap .calliope-sp-history-coming {
  background: #e5e7eb;
  color: #596170;
}
.calliope-sp-wrap .calliope-sp-history-pro-list {
  margin: 14px 0 16px 18px;
  color: #6b7280;
}
.calliope-sp-wrap .calliope-sp-history-pro-list li {
  margin-bottom: 7px;
}
.calliope-sp-wrap .calliope-sp-history-pro-cta {
  opacity: .9;
}
.calliope-sp-wrap .calliope-sp-history-pro-owned {
  background: #e9e7ef;
  color: #494052;
}
@media (max-width: 900px) {
  .calliope-sp-wrap .calliope-sp-history-overview { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
  .calliope-sp-wrap .calliope-sp-history-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .calliope-sp-wrap .calliope-sp-history-card__head { flex-direction: column; }
}

/* Step 2: complete Free History browser. */
.calliope-sp-wrap .calliope-sp-history-browser {
  margin-top: 18px;
  padding: 20px;
}
.calliope-sp-wrap .calliope-sp-history-browser__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}
.calliope-sp-wrap .calliope-sp-history-browser__head h3 {
  margin: 0 0 5px;
  font-size: 18px;
}
.calliope-sp-wrap .calliope-sp-history-browser__head p {
  max-width: 760px;
  margin: 0;
  color: var(--calliope-sp-muted);
  line-height: 1.5;
}

.calliope-sp-wrap .calliope-sp-history-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 14px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #eef0f3;
}
.calliope-sp-wrap .calliope-sp-history-toolbar__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  color: var(--calliope-sp-muted);
  font-size: 12px;
}
.calliope-sp-wrap .calliope-sp-history-toolbar__meta span:not(.calliope-sp-history-state) {
  display: inline-flex;
  align-items: center;
}
.calliope-sp-wrap .calliope-sp-history-inline-pro {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.calliope-sp-wrap .calliope-sp-history-result-count {
  flex: 0 0 auto;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--calliope-sp-purple-soft);
  color: var(--calliope-sp-purple);
  font-size: 12px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-history-filters {
  display: grid;
  grid-template-columns: minmax(260px, 2fr) minmax(150px, .8fr) minmax(150px, .8fr) auto;
  gap: 12px;
  align-items: end;
  padding: 14px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 10px;
  background: #fbfbfc;
}
.calliope-sp-wrap .calliope-sp-history-filter {
  display: grid;
  gap: 6px;
  min-width: 0;
}
.calliope-sp-wrap .calliope-sp-history-filter > span,
.calliope-sp-wrap .calliope-sp-history-pro-tools label > span {
  color: var(--calliope-sp-heading);
  font-size: 11px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-history-filter input,
.calliope-sp-wrap .calliope-sp-history-filter select,
.calliope-sp-wrap .calliope-sp-history-pro-tools input,
.calliope-sp-wrap .calliope-sp-history-pro-tools select {
  width: 100%;
  min-height: 36px;
}
.calliope-sp-wrap .calliope-sp-history-filter-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
}
.calliope-sp-wrap .calliope-sp-history-pro-tools {
  display: grid;
  grid-template-columns: minmax(145px, .8fr) minmax(145px, .8fr) minmax(175px, 1fr) auto;
  gap: 10px;
  align-items: end;
  margin-top: 10px;
  padding: 12px 14px;
  border: 1px dashed #c9cdd4;
  border-radius: 10px;
  background: #f3f4f6;
  opacity: .82;
}
.calliope-sp-wrap .calliope-sp-history-pro-tools__title {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 7px;
  color: #5f6672;
  font-size: 12px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-history-pro-tools label {
  display: grid;
  gap: 5px;
}
.calliope-sp-wrap .calliope-sp-history-pro-tools input:disabled,
.calliope-sp-wrap .calliope-sp-history-pro-tools select:disabled,
.calliope-sp-wrap .calliope-sp-history-pro-tools .button:disabled {
  color: #7a818c;
  background: #e9eaed;
  border-color: #d5d7dc;
  cursor: not-allowed;
}
.calliope-sp-wrap .calliope-sp-history-table-wrap {
  overflow-x: auto;
  margin-top: 16px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 10px;
  background: #fff;
}
.calliope-sp-wrap .calliope-sp-history-table {
  min-width: 1120px;
  border: 0;
  box-shadow: none;
}
.calliope-sp-wrap .calliope-sp-history-table thead th {
  padding: 10px 12px;
  color: var(--calliope-sp-heading);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .03em;
}
.calliope-sp-wrap .calliope-sp-history-table tbody td {
  padding: 12px;
  vertical-align: top;
  color: var(--calliope-sp-text);
  font-size: 12px;
}
.calliope-sp-wrap .calliope-sp-history-publication {
  display: flex;
  gap: 10px;
  min-width: 245px;
}
.calliope-sp-wrap .calliope-sp-history-publication img,
.calliope-sp-wrap .calliope-sp-history-thumb-placeholder {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border-radius: 8px;
}
.calliope-sp-wrap .calliope-sp-history-publication img {
  object-fit: cover;
  border: 1px solid var(--calliope-sp-border);
}
.calliope-sp-wrap .calliope-sp-history-thumb-placeholder {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f0f1f4;
  color: #737b88;
  font-size: 21px;
}
.calliope-sp-wrap .calliope-sp-history-publication strong,
.calliope-sp-wrap .calliope-sp-history-publication span,
.calliope-sp-wrap .calliope-sp-history-publication a {
  display: block;
}
.calliope-sp-wrap .calliope-sp-history-publication strong {
  max-width: 240px;
  color: var(--calliope-sp-heading);
  font-size: 12.5px;
  line-height: 1.35;
}
.calliope-sp-wrap .calliope-sp-history-publication span,
.calliope-sp-wrap .calliope-sp-history-publication a {
  margin-top: 3px;
  color: var(--calliope-sp-muted);
  font-size: 11px;
}
.calliope-sp-wrap .calliope-sp-history-publication a {
  color: var(--calliope-sp-purple);
  text-decoration: none;
}
.calliope-sp-wrap .calliope-sp-history-destination {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  min-width: 150px;
}
.calliope-sp-wrap .calliope-sp-history-network-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
}
.calliope-sp-wrap .calliope-sp-history-network-icon svg {
  width: 22px;
  height: 22px;
}
.calliope-sp-wrap .calliope-sp-history-destination strong,
.calliope-sp-wrap .calliope-sp-history-destination span {
  display: block;
}
.calliope-sp-wrap .calliope-sp-history-destination strong {
  color: var(--calliope-sp-heading);
  line-height: 1.3;
}
.calliope-sp-wrap .calliope-sp-history-destination span {
  max-width: 180px;
  margin-top: 3px;
  overflow-wrap: anywhere;
  color: var(--calliope-sp-muted);
  font-size: 10.5px;
  line-height: 1.35;
}
.calliope-sp-wrap .calliope-sp-history-chip-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  max-width: 140px;
}
.calliope-sp-wrap .calliope-sp-history-chip,
.calliope-sp-wrap .calliope-sp-history-status-badge {
  display: inline-flex;
  align-items: center;
  min-height: 23px;
  padding: 3px 8px;
  border-radius: 999px;
  background: #eef1f5;
  color: #4b5563;
  font-size: 10.5px;
  font-weight: 750;
  line-height: 1.2;
}
.calliope-sp-wrap .calliope-sp-history-chip.is-ai {
  background: var(--calliope-sp-purple-soft);
  color: var(--calliope-sp-purple);
}
.calliope-sp-wrap .calliope-sp-history-chip.is-muted {
  color: #7a818c;
}
.calliope-sp-wrap .calliope-sp-history-source-main,
.calliope-sp-wrap .calliope-sp-history-source-detail,
.calliope-sp-wrap .calliope-sp-history-date {
  display: block;
}
.calliope-sp-wrap .calliope-sp-history-source-main {
  color: var(--calliope-sp-heading);
}
.calliope-sp-wrap .calliope-sp-history-source-detail,
.calliope-sp-wrap .calliope-sp-history-date {
  margin-top: 3px;
  color: var(--calliope-sp-muted);
  font-size: 10.5px;
  line-height: 1.35;
}
.calliope-sp-wrap .calliope-sp-history-status-badge.is-success {
  background: #eaf8ef;
  color: #166534;
}
.calliope-sp-wrap .calliope-sp-history-status-badge.is-failed {
  background: #fff0ef;
  color: #b42318;
}
.calliope-sp-wrap .calliope-sp-history-status-badge.is-pending,
.calliope-sp-wrap .calliope-sp-history-status-badge.is-warning {
  background: #fff7e6;
  color: #8a5a00;
}
.calliope-sp-wrap .calliope-sp-history-status-badge.is-neutral {
  background: #eef1f5;
  color: #596170;
}
.calliope-sp-wrap .calliope-sp-history-result-cell {
  min-width: 190px;
  max-width: 280px;
}
.calliope-sp-wrap .calliope-sp-history-error {
  display: block;
  color: #a12b22;
  line-height: 1.4;
}
.calliope-sp-wrap .calliope-sp-history-muted {
  display: block;
  color: var(--calliope-sp-muted);
  line-height: 1.4;
}
.calliope-sp-wrap .calliope-sp-history-details {
  margin-top: 7px;
}
.calliope-sp-wrap .calliope-sp-history-details summary {
  width: fit-content;
  color: var(--calliope-sp-purple);
  font-size: 11px;
  font-weight: 750;
  cursor: pointer;
}
.calliope-sp-wrap .calliope-sp-history-details dl {
  display: grid;
  gap: 5px;
  margin: 8px 0 0;
  padding: 9px;
  border-radius: 8px;
  background: #f7f7f9;
}
.calliope-sp-wrap .calliope-sp-history-details dl > div {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 7px;
}
.calliope-sp-wrap .calliope-sp-history-details dt {
  color: var(--calliope-sp-muted);
  font-size: 10px;
  font-weight: 700;
}
.calliope-sp-wrap .calliope-sp-history-details dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
  color: var(--calliope-sp-text);
  font-size: 10px;
}
.calliope-sp-wrap .calliope-sp-history-empty {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 16px;
  padding: 22px;
  border: 1px dashed #ccd0d7;
  border-radius: 10px;
  background: #fafafb;
  color: var(--calliope-sp-muted);
}
.calliope-sp-wrap .calliope-sp-history-empty .dashicons {
  color: var(--calliope-sp-purple);
  font-size: 24px;
}
.calliope-sp-wrap .calliope-sp-history-empty strong {
  display: block;
  margin-bottom: 4px;
  color: var(--calliope-sp-heading);
}
.calliope-sp-wrap .calliope-sp-history-empty p {
  margin: 0;
}
.calliope-sp-wrap .calliope-sp-history-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  color: var(--calliope-sp-muted);
  font-size: 11px;
}
.calliope-sp-wrap .calliope-sp-history-pagination .page-numbers {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin: 0;
}
.calliope-sp-wrap .calliope-sp-history-pagination .page-numbers li {
  margin: 0;
}
.calliope-sp-wrap .calliope-sp-history-pagination a.page-numbers,
.calliope-sp-wrap .calliope-sp-history-pagination span.page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  min-height: 30px;
  padding: 3px 8px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 7px;
  background: #fff;
  color: var(--calliope-sp-heading);
  text-decoration: none;
}
.calliope-sp-wrap .calliope-sp-history-pagination span.page-numbers.current {
  border-color: var(--calliope-sp-purple);
  background: var(--calliope-sp-purple-soft);
  color: var(--calliope-sp-purple);
  font-weight: 800;
}
@media (max-width: 1100px) {
  .calliope-sp-wrap .calliope-sp-history-filters { grid-template-columns: 1fr 1fr; }
  .calliope-sp-wrap .calliope-sp-history-filter--search { grid-column: 1 / -1; }
  .calliope-sp-wrap .calliope-sp-history-pro-tools { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 620px) {
  .calliope-sp-wrap .calliope-sp-history-browser { padding: 14px; }
  .calliope-sp-wrap .calliope-sp-history-browser__head,
  .calliope-sp-wrap .calliope-sp-history-pagination { align-items: flex-start; flex-direction: column; }
  .calliope-sp-wrap .calliope-sp-history-filters,
  .calliope-sp-wrap .calliope-sp-history-pro-tools { grid-template-columns: 1fr; }
  .calliope-sp-wrap .calliope-sp-history-filter--search { grid-column: auto; }
}

/* History Step 2 layout hardening — 1.5.25 */
.calliope-sp-wrap .calliope-sp-history-table {
  width: 100%;
  min-width: 1050px;
  table-layout: fixed;
}
.calliope-sp-wrap .calliope-sp-history-table col.calliope-sp-history-col-publication { width: 260px; }
.calliope-sp-wrap .calliope-sp-history-table col.calliope-sp-history-col-destination { width: 170px; }
.calliope-sp-wrap .calliope-sp-history-table col.calliope-sp-history-col-type { width: 110px; }
.calliope-sp-wrap .calliope-sp-history-table col.calliope-sp-history-col-source { width: 110px; }
.calliope-sp-wrap .calliope-sp-history-table col.calliope-sp-history-col-date { width: 130px; }
.calliope-sp-wrap .calliope-sp-history-table col.calliope-sp-history-col-status { width: 110px; }
.calliope-sp-wrap .calliope-sp-history-table col.calliope-sp-history-col-result { width: 160px; }
.calliope-sp-wrap .calliope-sp-history-table th,
.calliope-sp-wrap .calliope-sp-history-table td {
  box-sizing: border-box;
  overflow: hidden;
}
.calliope-sp-wrap .calliope-sp-history-publication,
.calliope-sp-wrap .calliope-sp-history-destination {
  min-width: 0;
  width: 100%;
}
.calliope-sp-wrap .calliope-sp-history-publication > div,
.calliope-sp-wrap .calliope-sp-history-destination > div {
  min-width: 0;
}
.calliope-sp-wrap .calliope-sp-history-publication strong {
  max-width: none;
  overflow-wrap: anywhere;
}
.calliope-sp-wrap .calliope-sp-history-destination span {
  max-width: 142px;
  overflow-wrap: anywhere;
}
.calliope-sp-wrap .calliope-sp-history-chip-stack {
  max-width: none;
  align-items: flex-start;
}
.calliope-sp-wrap .calliope-sp-history-chip,
.calliope-sp-wrap .calliope-sp-history-status-badge {
  white-space: nowrap;
}
.calliope-sp-wrap .calliope-sp-history-source-main,
.calliope-sp-wrap .calliope-sp-history-source-detail,
.calliope-sp-wrap .calliope-sp-history-date,
.calliope-sp-wrap .calliope-sp-history-result-cell > .calliope-sp-history-muted,
.calliope-sp-wrap .calliope-sp-history-result-cell > .calliope-sp-history-error {
  overflow-wrap: anywhere;
}
.calliope-sp-wrap .calliope-sp-history-result-cell .button-small {
  max-width: 100%;
  white-space: normal;
  text-align: center;
  line-height: 1.25;
}

.calliope-sp-wrap .calliope-sp-history-date {
  display: inline-block;
  font-size: 12px;
  line-height: 1.35;
  max-width: 126px;
  white-space: normal;
}
.calliope-sp-wrap .calliope-sp-history-details {
  overflow: visible;
}
.calliope-sp-wrap .calliope-sp-history-details dl {
  position: relative;
  z-index: 2;
  width: 320px;
  max-width: min(320px, 75vw);
  box-sizing: border-box;
}
.calliope-sp-wrap .calliope-sp-history-table tbody td:before {
  display: none;
}

@media (max-width: 920px) {
  .calliope-sp-wrap .calliope-sp-history-table-wrap {
    overflow: visible;
    border: 0;
    background: transparent;
  }
  .calliope-sp-wrap .calliope-sp-history-table {
    display: block;
    min-width: 0;
    background: transparent;
  }
  .calliope-sp-wrap .calliope-sp-history-table colgroup,
  .calliope-sp-wrap .calliope-sp-history-table thead {
    display: none;
  }
  .calliope-sp-wrap .calliope-sp-history-table tbody {
    display: grid;
    gap: 12px;
  }
  .calliope-sp-wrap .calliope-sp-history-table tbody tr {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0;
    overflow: hidden;
    border: 1px solid var(--calliope-sp-border);
    border-radius: 12px;
    background: #fff;
  }
  .calliope-sp-wrap .calliope-sp-history-table tbody tr:nth-child(odd),
  .calliope-sp-wrap .calliope-sp-history-table tbody tr:nth-child(even) {
    background: #fff;
  }
  .calliope-sp-wrap .calliope-sp-history-table tbody td {
    display: block;
    min-width: 0;
    padding: 12px 14px;
    border: 0;
    border-top: 1px solid #eef0f3;
  }
  .calliope-sp-wrap .calliope-sp-history-table tbody td:before {
    content: attr(data-label);
    display: block;
    margin-bottom: 7px;
    color: var(--calliope-sp-muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
  }
  .calliope-sp-wrap .calliope-sp-history-table tbody td.calliope-sp-history-publication-cell {
    grid-column: 1 / -1;
    border-top: 0;
  }
  .calliope-sp-wrap .calliope-sp-history-table tbody td.calliope-sp-history-result-cell {
    grid-column: 1 / -1;
  }
  .calliope-sp-wrap .calliope-sp-history-publication strong {
    font-size: 13px;
  }
  .calliope-sp-wrap .calliope-sp-history-destination span {
    max-width: none;
  }
  .calliope-sp-wrap .calliope-sp-history-details dl {
    width: 100%;
    max-width: 100%;
  }
}

@media (max-width: 560px) {
  .calliope-sp-wrap .calliope-sp-history-table tbody tr {
    grid-template-columns: 1fr;
  }
  .calliope-sp-wrap .calliope-sp-history-table tbody td.calliope-sp-history-publication-cell,
  .calliope-sp-wrap .calliope-sp-history-table tbody td.calliope-sp-history-result-cell {
    grid-column: auto;
  }
}
/* Keep the expandable result metadata readable inside its fixed result column. */
.calliope-sp-wrap .calliope-sp-history-table col.calliope-sp-history-col-publication { width: 260px; }
.calliope-sp-wrap .calliope-sp-history-table col.calliope-sp-history-col-result { width: 160px; }
.calliope-sp-wrap .calliope-sp-history-result-cell .calliope-sp-history-details dl {
  width: 100%;
  max-width: 100%;
}
.calliope-sp-wrap .calliope-sp-history-result-cell .calliope-sp-history-details dl > div {
  grid-template-columns: minmax(0, 1fr);
  gap: 2px;
}

/* History Step 3 — per-destination retry */
.calliope-sp-wrap .calliope-sp-history-retry-form {
  margin: 8px 0 0;
}
.calliope-sp-wrap .calliope-sp-history-retry-button {
  border-color: #6d28d9;
  color: #6d28d9;
  font-weight: 700;
}
.calliope-sp-wrap .calliope-sp-history-retry-button:hover,
.calliope-sp-wrap .calliope-sp-history-retry-button:focus {
  border-color: #5b21b6;
  color: #5b21b6;
}



@media (min-width: 960px) {
  .calliope-sp-wrap .calliope-sp-settings-card--ai {
    grid-column: 1;
    grid-row: 2;
    align-self: stretch;
  }
  .calliope-sp-wrap .calliope-sp-settings-card--maintenance {
    grid-column: 2;
    grid-row: 2;
    align-self: stretch;
  }
  .calliope-sp-wrap .calliope-sp-settings-card--templates {
    grid-column: 1 / -1;
    grid-row: 3;
    align-self: start;
  }

  .calliope-sp-wrap .calliope-sp-settings-card--ai .calliope-sp-settings-form {
    flex: 1 1 auto;
    min-height: 0;
  }

  .calliope-sp-wrap .calliope-sp-settings-card--ai .calliope-sp-settings-actions {
    margin-top: auto;
  }
}

.calliope-sp-wrap .calliope-sp-settings-subsection--first {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

/* Free Step 4 Analytics — 1.5.30 */
.calliope-sp-wrap .calliope-sp-settings-subsection {
  margin-top: 4px;
  padding-top: 18px;
  border-top: 1px solid var(--calliope-sp-border);
  display: grid;
  gap: 14px;
}
.calliope-sp-wrap .calliope-sp-settings-subsection.calliope-sp-settings-subsection--first {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.calliope-sp-wrap .calliope-sp-analytics-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
}
.calliope-sp-wrap .calliope-sp-analytics-head h3 {
  margin: 3px 0 6px;
  font-size: 22px;
  color: var(--calliope-sp-heading);
}
.calliope-sp-wrap .calliope-sp-analytics-head p {
  margin: 0;
  color: var(--calliope-sp-muted);
  max-width: 720px;
}
.calliope-sp-wrap .calliope-sp-analytics-periods {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex: 0 0 auto;
}
.calliope-sp-wrap .calliope-sp-analytics-metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 16px;
}
.calliope-sp-wrap .calliope-sp-analytics-metric {
  min-width: 0;
  padding: 12px 13px;
}
.calliope-sp-wrap .calliope-sp-analytics-metric > span {
  display: block;
  color: var(--calliope-sp-muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .03em;
}
.calliope-sp-wrap .calliope-sp-analytics-metric > strong {
  display: block;
  margin: 6px 0 3px;
  color: var(--calliope-sp-heading);
  font-size: 24px;
  line-height: 1.1;
}
.calliope-sp-wrap .calliope-sp-analytics-metric > small {
  display: block;
  color: var(--calliope-sp-muted);
  font-size: 11px;
  line-height: 1.35;
}
.calliope-sp-wrap .calliope-sp-analytics-metric.is-success { border-top: 3px solid #16a05d; }
.calliope-sp-wrap .calliope-sp-analytics-metric.is-failed { border-top: 3px solid #d63638; }
.calliope-sp-wrap .calliope-sp-analytics-table-card { margin-bottom: 16px; }

.calliope-sp-wrap .calliope-sp-analytics-activity-card {
  margin-bottom: 16px;
  padding: 16px;
}
.calliope-sp-wrap .calliope-sp-analytics-activity-head {
  align-items: flex-end;
}
.calliope-sp-wrap .calliope-sp-analytics-activity-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 8px;
}
.calliope-sp-wrap .calliope-sp-analytics-activity-controls form {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  margin: 0;
}
.calliope-sp-wrap .calliope-sp-analytics-activity-controls label {
  display: grid;
  gap: 4px;
}
.calliope-sp-wrap .calliope-sp-analytics-activity-controls label > span {
  color: var(--calliope-sp-muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .03em;
}
.calliope-sp-wrap .calliope-sp-analytics-activity-controls select {
  min-width: 170px;
}
.calliope-sp-wrap .calliope-sp-analytics-pro-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.calliope-sp-wrap .calliope-sp-analytics-pro-controls > span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 30px;
  padding: 4px 9px;
  border: 1px dashed #cfd4dd;
  border-radius: 6px;
  background: #f1f2f4;
  color: #7a8391;
  font-size: 11px;
  font-weight: 700;
  cursor: not-allowed;
}
.calliope-sp-wrap .calliope-sp-analytics-chart-legend {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: -2px 0 8px 48px;
  color: var(--calliope-sp-muted);
  font-size: 12px;
  font-weight: 700;
}
.calliope-sp-wrap .calliope-sp-analytics-chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.calliope-sp-wrap .calliope-sp-analytics-chart-legend i {
  display: inline-block;
  width: 18px;
  height: 3px;
  border-radius: 999px;
}
.calliope-sp-wrap .calliope-sp-analytics-chart-legend .is-success i { background: #16a05d; }
.calliope-sp-wrap .calliope-sp-analytics-chart-legend .is-failed i { background: #d63638; }
.calliope-sp-wrap .calliope-sp-analytics-chart {
  width: 100%;
  min-height: 230px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}
.calliope-sp-wrap .calliope-sp-analytics-chart svg {
  display: block;
  width: 100%;
  height: auto;
  min-height: 230px;
}
.calliope-sp-wrap .calliope-sp-chart-grid {
  stroke: #e7e9ee;
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}
.calliope-sp-wrap .calliope-sp-chart-y-label,
.calliope-sp-wrap .calliope-sp-chart-x-label {
  fill: #7a8391;
  font-size: 11px;
  font-family: inherit;
}
.calliope-sp-wrap .calliope-sp-chart-line {
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}
.calliope-sp-wrap .calliope-sp-chart-line.is-success { stroke: #16a05d; }
.calliope-sp-wrap .calliope-sp-chart-line.is-failed { stroke: #d63638; }
.calliope-sp-wrap .calliope-sp-chart-point {
  stroke: #fff;
  stroke-width: 1.5;
  vector-effect: non-scaling-stroke;
}
.calliope-sp-wrap .calliope-sp-chart-point.is-success { fill: #16a05d; }
.calliope-sp-wrap .calliope-sp-chart-point.is-failed { fill: #d63638; }
.calliope-sp-wrap .calliope-sp-analytics-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}
.calliope-sp-wrap .calliope-sp-analytics-section-head h3 { margin: 0 0 5px; }
.calliope-sp-wrap .calliope-sp-analytics-section-head p { margin: 0; color: var(--calliope-sp-muted); }
.calliope-sp-wrap .calliope-sp-analytics-table-wrap { overflow-x: auto; border: 1px solid var(--calliope-sp-border); border-radius: 10px; }
.calliope-sp-wrap .calliope-sp-analytics-table { margin: 0; border: 0; min-width: 660px; }
.calliope-sp-wrap .calliope-sp-analytics-table th { color: var(--calliope-sp-heading); font-size: 11px; text-transform: uppercase; letter-spacing: .03em; }
.calliope-sp-wrap .calliope-sp-analytics-table td, .calliope-sp-wrap .calliope-sp-analytics-table th { padding: 11px 14px; }
.calliope-sp-wrap .calliope-sp-analytics-pro {
  position: relative;
  padding: 15px 16px;
  background: linear-gradient(180deg, #f8f8fa 0%, #f3f4f7 100%);
  border: 1px dashed #cfd4dd;
  opacity: 1;
}
.calliope-sp-wrap .calliope-sp-analytics-pro__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.calliope-sp-wrap .calliope-sp-analytics-pro__head h3 {
  margin: 2px 0 0;
  color: #555f70;
  font-size: 16px;
}
.calliope-sp-wrap .calliope-sp-analytics-pro-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 11px 0 10px;
}
.calliope-sp-wrap .calliope-sp-analytics-pro-grid > div {
  min-width: 0;
  border: 1px solid #d9dde5;
  border-radius: 8px;
  background: #eef0f3;
  padding: 9px 11px;
}
.calliope-sp-wrap .calliope-sp-analytics-pro-grid strong,
.calliope-sp-wrap .calliope-sp-analytics-pro-grid span { display: block; }
.calliope-sp-wrap .calliope-sp-analytics-pro-grid strong {
  margin-bottom: 3px;
  color: #596273;
  font-size: 12px;
  line-height: 1.25;
}
.calliope-sp-wrap .calliope-sp-analytics-pro-grid span {
  color: #747d8b;
  font-size: 11px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.calliope-sp-wrap .calliope-sp-analytics-pro .calliope-sp-history-pro-cta {
  min-height: 32px;
  padding: 4px 12px;
  line-height: 22px;
}
@media (max-width: 840px) {
  .calliope-sp-wrap .calliope-sp-analytics-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .calliope-sp-wrap .calliope-sp-analytics-head,
  .calliope-sp-wrap .calliope-sp-analytics-section-head { flex-direction: column; }
  .calliope-sp-wrap .calliope-sp-analytics-activity-controls { width: 100%; justify-content: flex-start; }
  .calliope-sp-wrap .calliope-sp-analytics-activity-controls form { flex-wrap: wrap; }
  .calliope-sp-wrap .calliope-sp-analytics-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .calliope-sp-wrap .calliope-sp-analytics-pro-grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .calliope-sp-wrap .calliope-sp-analytics-metrics { grid-template-columns: 1fr; }
  .calliope-sp-wrap .calliope-sp-analytics-periods { width: 100%; }
  .calliope-sp-wrap .calliope-sp-analytics-periods .button { flex: 1 1 auto; text-align: center; }
  .calliope-sp-wrap .calliope-sp-analytics-activity-controls form { width: 100%; }
  .calliope-sp-wrap .calliope-sp-analytics-activity-controls label { flex: 1 1 100%; }
  .calliope-sp-wrap .calliope-sp-analytics-activity-controls select { width: 100%; max-width: none; }
  .calliope-sp-wrap .calliope-sp-analytics-chart-legend { margin-left: 0; }
  .calliope-sp-wrap .calliope-sp-analytics-chart { min-height: 190px; }
  .calliope-sp-wrap .calliope-sp-analytics-chart svg { min-height: 190px; }
}

/* Free Step 6 — per-network Social Templates. */
.calliope-sp-wrap .calliope-sp-template-settings-form {
  gap: 12px;
}
.calliope-sp-wrap .calliope-sp-template-tokens {
  padding: 12px 14px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 10px;
  background: #fbfbfc;
}
.calliope-sp-wrap .calliope-sp-template-tokens > strong {
  display: block;
  margin-bottom: 8px;
  color: var(--calliope-sp-heading);
  font-size: 12px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-template-token-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.calliope-sp-wrap .calliope-sp-template-token {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 2px 8px;
  border: 1px solid #ded5f0;
  border-radius: 999px;
  background: #f8f4ff;
}
.calliope-sp-wrap .calliope-sp-template-token code {
  padding: 0;
  background: transparent;
  color: var(--calliope-sp-purple);
  font-size: 11px;
  font-weight: 700;
}
.calliope-sp-wrap .calliope-sp-template-tokens small {
  display: block;
  margin-top: 8px;
  color: var(--calliope-sp-muted);
  font-size: 11px;
  line-height: 1.4;
}
.calliope-sp-wrap .calliope-sp-template-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.calliope-sp-wrap .calliope-sp-template-card {
  min-width: 0;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 9px;
  background: #fff;
  overflow: hidden;
}
.calliope-sp-wrap .calliope-sp-template-card[open] {
  border-color: #c9b8e9;
  box-shadow: 0 0 0 1px rgba(109, 40, 217, .05);
}
.calliope-sp-wrap .calliope-sp-template-card summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 44px;
  padding: 8px 11px;
  cursor: pointer;
  list-style: none;
  background: #fbfbfc;
}
.calliope-sp-wrap .calliope-sp-template-card summary::-webkit-details-marker {
  display: none;
}
.calliope-sp-wrap .calliope-sp-template-card summary:hover,
.calliope-sp-wrap .calliope-sp-template-card summary:focus-visible {
  background: #faf7ff;
  outline: none;
}
.calliope-sp-wrap .calliope-sp-template-card__network {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: var(--calliope-sp-heading);
}
.calliope-sp-wrap .calliope-sp-template-card__network svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}
.calliope-sp-wrap .calliope-sp-template-card__network strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}
.calliope-sp-wrap .calliope-sp-template-card__free {
  flex: 0 0 auto;
  padding: 2px 7px;
  border-radius: 999px;
  background: #eef2f7;
  color: #596274;
  font-size: 10px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-template-card__body {
  display: grid;
  gap: 6px;
  padding: 10px 11px 11px;
  border-top: 1px solid #eef0f3;
}
.calliope-sp-wrap .calliope-sp-template-card__body textarea {
  width: 100%;
  min-height: 112px;
  resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
  line-height: 1.45;
}
.calliope-sp-wrap .calliope-sp-template-card__body p {
  margin: 0;
  color: var(--calliope-sp-muted);
  font-size: 11px;
}
.calliope-sp-wrap .calliope-sp-template-pro-teaser {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 12px;
  border: 1px dashed #cfd3da;
  border-radius: 10px;
  background: #f4f5f7;
}
.calliope-sp-wrap .calliope-sp-template-pro-teaser > div {
  min-width: 0;
}
.calliope-sp-wrap .calliope-sp-template-pro-teaser strong,
.calliope-sp-wrap .calliope-sp-template-pro-teaser span:not(.calliope-sp-pro-badge):not(.calliope-sp-template-roadmap) {
  display: block;
}
.calliope-sp-wrap .calliope-sp-template-pro-teaser strong {
  color: #4d5664;
  font-size: 12px;
}
.calliope-sp-wrap .calliope-sp-template-pro-teaser span:not(.calliope-sp-pro-badge):not(.calliope-sp-template-roadmap) {
  margin-top: 3px;
  color: #747d8b;
  font-size: 11px;
  line-height: 1.35;
}
.calliope-sp-wrap .calliope-sp-template-pro-teaser .button {
  flex: 0 0 auto;
}
@media (max-width: 720px) {
  .calliope-sp-wrap .calliope-sp-template-grid {
    grid-template-columns: 1fr;
  }
  .calliope-sp-wrap .calliope-sp-template-pro-teaser {
    align-items: flex-start;
    flex-direction: column;
  }
}

.calliope-sp-wrap .calliope-sp-template-roadmap {
  display: inline-flex;
  margin-left: 5px;
  color: #747d8b;
  font-size: 10px;
  font-weight: 700;
}

/* Free Step 7 — Smart Tags and dynamic Social Templates editor. */
.calliope-sp-wrap .calliope-sp-template-workspace {
  display: grid;
  gap: 14px;
}
.calliope-sp-wrap .calliope-sp-template-picker-block,
.calliope-sp-wrap .calliope-sp-smart-tags,
.calliope-sp-wrap .calliope-sp-template-editor-panel {
  border: 1px solid var(--calliope-sp-border);
  border-radius: 10px;
  background: #fff;
}
.calliope-sp-wrap .calliope-sp-template-picker-block,
.calliope-sp-wrap .calliope-sp-smart-tags {
  padding: 12px;
}
.calliope-sp-wrap .calliope-sp-template-section-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.calliope-sp-wrap .calliope-sp-template-section-title strong {
  display: block;
  color: var(--calliope-sp-heading);
  font-size: 12px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-template-section-title span {
  display: block;
  margin-top: 3px;
  color: var(--calliope-sp-muted);
  font-size: 11px;
  line-height: 1.4;
}
.calliope-sp-wrap .calliope-sp-template-network-picker {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}
.calliope-sp-wrap .calliope-sp-template-network-button {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
  min-height: 38px;
  padding: 7px 9px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 8px;
  background: #fbfbfc;
  color: var(--calliope-sp-heading);
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  text-align: left;
  transition: border-color .15s ease, background .15s ease, box-shadow .15s ease, color .15s ease;
}
.calliope-sp-wrap .calliope-sp-template-network-button:hover,
.calliope-sp-wrap .calliope-sp-template-network-button:focus-visible {
  border-color: var(--calliope-sp-purple);
  background: #faf7ff;
  outline: none;
}
.calliope-sp-wrap .calliope-sp-template-network-button.is-active {
  border-color: var(--calliope-sp-purple);
  background: var(--calliope-sp-purple-soft);
  color: var(--calliope-sp-purple);
  box-shadow: 0 0 0 1px rgba(109, 40, 217, .08);
}
.calliope-sp-wrap .calliope-sp-template-network-button__icon {
  display: inline-flex;
  flex: 0 0 18px;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
}
.calliope-sp-wrap .calliope-sp-template-network-button__icon svg {
  display: block;
  width: 18px;
  height: 18px;
}
.calliope-sp-wrap .calliope-sp-smart-tags {
  background: #fbfbfc;
}
.calliope-sp-wrap .calliope-sp-smart-tag-group {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: start;
  gap: 8px;
  padding: 7px 0;
  border-top: 1px solid #eef0f3;
}
.calliope-sp-wrap .calliope-sp-smart-tag-group:first-of-type {
  border-top: 0;
  padding-top: 0;
}
.calliope-sp-wrap .calliope-sp-smart-tag-group__label {
  padding-top: 6px;
  color: var(--calliope-sp-muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .03em;
  text-transform: uppercase;
}
.calliope-sp-wrap .calliope-sp-smart-tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.calliope-sp-wrap .calliope-sp-smart-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  padding: 4px 8px;
  border: 1px solid #ded5f0;
  border-radius: 7px;
  background: #fff;
  color: var(--calliope-sp-heading);
  cursor: pointer;
  font: inherit;
  transition: border-color .15s ease, background .15s ease, transform .15s ease;
}
.calliope-sp-wrap .calliope-sp-smart-tag:hover,
.calliope-sp-wrap .calliope-sp-smart-tag:focus-visible {
  border-color: var(--calliope-sp-purple);
  background: #f8f4ff;
  outline: none;
  transform: translateY(-1px);
}
.calliope-sp-wrap .calliope-sp-smart-tag code {
  padding: 0;
  background: transparent;
  color: var(--calliope-sp-purple);
  font-size: 10px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-smart-tag > span {
  color: var(--calliope-sp-muted);
  font-size: 10px;
  font-weight: 600;
}
.calliope-sp-wrap .calliope-sp-template-safety-note {
  margin: 8px 0 0;
  color: var(--calliope-sp-muted);
  font-size: 10px;
  line-height: 1.4;
}
.calliope-sp-wrap .calliope-sp-template-editors {
  min-width: 0;
}
.calliope-sp-wrap .calliope-sp-template-editor-panel {
  min-width: 0;
  padding: 12px;
  box-shadow: 0 8px 22px rgba(35, 28, 65, .035);
}
.calliope-sp-wrap .calliope-sp-template-editor-panel[hidden] {
  display: none !important;
}
.calliope-sp-wrap .calliope-sp-template-editor-head,
.calliope-sp-wrap .calliope-sp-template-editor-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.calliope-sp-wrap .calliope-sp-template-editor-head {
  margin-bottom: 9px;
}
.calliope-sp-wrap .calliope-sp-template-editor-network {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}
.calliope-sp-wrap .calliope-sp-template-editor-network > svg {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
}
.calliope-sp-wrap .calliope-sp-template-editor-network strong,
.calliope-sp-wrap .calliope-sp-template-editor-network span {
  display: block;
}
.calliope-sp-wrap .calliope-sp-template-editor-network strong {
  color: var(--calliope-sp-heading);
  font-size: 13px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-template-editor-network span {
  margin-top: 2px;
  color: var(--calliope-sp-muted);
  font-size: 10px;
}
.calliope-sp-wrap .calliope-sp-template-editor-state {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  background: #eef2f7;
  color: #596274;
  font-size: 10px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-template-editor-state.is-custom {
  background: #f2eaff;
  color: var(--calliope-sp-purple);
}
.calliope-sp-wrap .calliope-sp-template-editor-panel textarea {
  display: block;
  width: 100%;
  min-height: 210px;
  max-height: 520px;
  padding: 12px;
  resize: vertical;
  border-color: #cfd6e2;
  border-radius: 8px;
  background: #fff;
  color: var(--calliope-sp-heading);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
  line-height: 1.6;
  box-sizing: border-box;
}
.calliope-sp-wrap .calliope-sp-template-editor-panel textarea:focus {
  border-color: var(--calliope-sp-purple);
  box-shadow: var(--calliope-sp-focus);
  outline: none;
}
.calliope-sp-wrap .calliope-sp-template-editor-footer {
  margin-top: 9px;
}
.calliope-sp-wrap .calliope-sp-template-char-count {
  color: var(--calliope-sp-muted);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}
.calliope-sp-wrap .calliope-sp-template-editor-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}
.calliope-sp-wrap .calliope-sp-template-editor-notice {
  min-height: 17px;
  color: var(--calliope-sp-purple);
  font-size: 11px;
  font-weight: 700;
}

@media (max-width: 680px) {
  .calliope-sp-wrap .calliope-sp-template-network-picker {
    grid-template-columns: 1fr;
  }
  .calliope-sp-wrap .calliope-sp-smart-tag-group {
    grid-template-columns: 1fr;
    gap: 5px;
  }
  .calliope-sp-wrap .calliope-sp-smart-tag-group__label {
    padding-top: 0;
  }
  .calliope-sp-wrap .calliope-sp-template-editor-head,
  .calliope-sp-wrap .calliope-sp-template-editor-footer {
    align-items: flex-start;
    flex-direction: column;
  }
  .calliope-sp-wrap .calliope-sp-template-editor-actions {
    justify-content: flex-start;
  }
}

@media (min-width: 960px) {
  .calliope-sp-wrap .calliope-sp-settings-card--templates .calliope-sp-template-network-picker {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

/* Step 8: provider-aware platform preview before publishing. */
.calliope-sp-wrap .calliope-sp-platform-preview-section {
  margin-top: 18px;
}
.calliope-sp-wrap .calliope-sp-platform-preview {
  padding: 18px;
}
.calliope-sp-wrap .calliope-sp-platform-preview__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}
.calliope-sp-wrap .calliope-sp-platform-preview__head h3 {
  margin: 0 0 5px;
  font-size: 18px;
}
.calliope-sp-wrap .calliope-sp-platform-preview__head p {
  max-width: 760px;
  margin: 0;
  color: var(--calliope-sp-muted);
  line-height: 1.5;
}
.calliope-sp-wrap .calliope-sp-platform-preview__actions {
  display: flex;
  flex: 0 1 auto;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}
.calliope-sp-wrap .calliope-sp-platform-preview__summary {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  color: var(--calliope-sp-muted);
  font-size: 12px;
  font-weight: 700;
}
.calliope-sp-wrap .calliope-sp-platform-preview__summary .is-ready { color: #087443; }
.calliope-sp-wrap .calliope-sp-platform-preview__summary .is-warning { color: #8a5a00; }
.calliope-sp-wrap .calliope-sp-platform-preview__summary .is-invalid { color: #b42318; }
.calliope-sp-wrap .calliope-sp-preview-summary-sep { color: #a0a7b3; }
.calliope-sp-wrap .calliope-sp-platform-preview__empty {
  margin-top: 14px;
  padding: 14px 16px;
  border: 1px dashed var(--calliope-sp-border);
  border-radius: 10px;
  background: #fbfbfc;
  color: var(--calliope-sp-muted);
  text-align: center;
}
.calliope-sp-wrap .calliope-sp-platform-preview__tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 7px;
  margin-top: 16px;
  padding-bottom: 0;
  overflow: visible;
}
.calliope-sp-wrap .calliope-sp-platform-preview__tab {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 7px 10px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 9px;
  background: #fff;
  color: var(--calliope-sp-heading);
  font: inherit;
  font-size: 12px;
  font-weight: 750;
  white-space: nowrap;
  cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.calliope-sp-wrap .calliope-sp-platform-preview__tab:hover,
.calliope-sp-wrap .calliope-sp-platform-preview__tab:focus-visible,
.calliope-sp-wrap .calliope-sp-platform-preview__tab.is-active {
  border-color: var(--calliope-sp-purple);
  background: #fbf8ff;
  box-shadow: 0 0 0 1px rgba(124, 58, 237, .08);
  outline: none;
}
.calliope-sp-wrap .calliope-sp-platform-preview__tab-state {
  padding: 2px 6px;
  border-radius: 999px;
  background: #eef2f7;
  color: #536079;
  font-size: 10px;
  line-height: 1.3;
}
.calliope-sp-wrap .calliope-sp-platform-preview__tab.is-ready .calliope-sp-platform-preview__tab-state {
  background: #e9f8ee;
  color: #087443;
}
.calliope-sp-wrap .calliope-sp-platform-preview__tab.is-warning .calliope-sp-platform-preview__tab-state {
  background: #fff5da;
  color: #8a5a00;
}
.calliope-sp-wrap .calliope-sp-platform-preview__tab.is-invalid .calliope-sp-platform-preview__tab-state {
  background: #fff0ef;
  color: #b42318;
}
.calliope-sp-wrap .calliope-sp-platform-preview__body {
  margin-top: 10px;
}
.calliope-sp-wrap .calliope-sp-platform-card {
  overflow: hidden;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 12px;
  background: #fff;
}
.calliope-sp-wrap .calliope-sp-platform-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 14px;
  border-bottom: 1px solid #edf0f4;
  background: #fbfbfc;
}
.calliope-sp-wrap .calliope-sp-platform-card__head > div:first-child,
.calliope-sp-wrap .calliope-sp-platform-card__head-right {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.calliope-sp-wrap .calliope-sp-platform-card__head strong {
  color: var(--calliope-sp-heading);
  font-size: 14px;
}
.calliope-sp-wrap .calliope-sp-platform-card__head small {
  color: var(--calliope-sp-muted);
  font-size: 11px;
}
.calliope-sp-wrap .calliope-sp-platform-card__template {
  padding: 3px 7px;
  border-radius: 999px;
  background: var(--calliope-sp-purple-soft);
  color: var(--calliope-sp-purple);
  font-size: 10px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-platform-preview__status {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  background: #eef2f7;
  color: #536079;
  font-size: 11px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-platform-preview__status.is-ready { background: #e9f8ee; color: #087443; }
.calliope-sp-wrap .calliope-sp-platform-preview__status.is-warning { background: #fff5da; color: #8a5a00; }
.calliope-sp-wrap .calliope-sp-platform-preview__status.is-invalid { background: #fff0ef; color: #b42318; }
.calliope-sp-wrap .calliope-sp-platform-card__content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 280px);
  gap: 12px 20px;
  padding: 16px;
}
.calliope-sp-wrap .calliope-sp-platform-card__content h4 {
  grid-column: 1;
  margin: 0;
  color: var(--calliope-sp-heading);
  font-size: 16px;
}
.calliope-sp-wrap .calliope-sp-platform-card__text {
  grid-column: 1;
  min-height: 48px;
  color: var(--calliope-sp-text);
  font-size: 13px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}
.calliope-sp-wrap .calliope-sp-platform-card__text[data-empty="1"] {
  color: var(--calliope-sp-muted);
}
.calliope-sp-wrap .calliope-sp-platform-card__field {
  grid-column: 1;
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  padding-top: 8px;
  border-top: 1px solid #f0f1f3;
  font-size: 12px;
}
.calliope-sp-wrap .calliope-sp-platform-card__field strong {
  color: var(--calliope-sp-heading);
}
.calliope-sp-wrap .calliope-sp-platform-card__field span,
.calliope-sp-wrap .calliope-sp-platform-card__field a {
  min-width: 0;
  overflow-wrap: anywhere;
}
.calliope-sp-wrap .calliope-sp-platform-card__media {
  grid-column: 2;
  grid-row: 1 / span 6;
  min-width: 0;
}
.calliope-sp-wrap .calliope-sp-platform-card__media-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
  color: var(--calliope-sp-muted);
  font-size: 11px;
}
.calliope-sp-wrap .calliope-sp-platform-card__media-head strong {
  color: var(--calliope-sp-heading);
}
.calliope-sp-wrap .calliope-sp-platform-card__media img {
  display: block;
  width: 100%;
  max-height: 250px;
  object-fit: contain;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #f7f8fa;
}
.calliope-sp-wrap .calliope-sp-platform-card__media-placeholder {
  display: flex;
  min-height: 150px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 6px;
  border: 1px dashed var(--calliope-sp-border);
  border-radius: 10px;
  background: #f8f9fb;
  color: var(--calliope-sp-muted);
  font-size: 12px;
  text-align: center;
}
.calliope-sp-wrap .calliope-sp-platform-card__media-placeholder .dashicons {
  width: 26px;
  height: 26px;
  font-size: 26px;
}
.calliope-sp-wrap .calliope-sp-platform-card__validation {
  padding: 10px 14px;
  border-top: 1px solid #edf0f4;
  background: #f8faf9;
  color: #087443;
  font-size: 12px;
}
.calliope-sp-wrap .calliope-sp-platform-card__validation.is-warning {
  background: #fffaf0;
  color: #8a5a00;
}
.calliope-sp-wrap .calliope-sp-platform-card__validation.is-invalid {
  background: #fff5f4;
  color: #b42318;
}
.calliope-sp-wrap .calliope-sp-platform-card__validation ul {
  margin: 0;
  padding-left: 18px;
}
.calliope-sp-wrap .calliope-sp-platform-card__validation li + li {
  margin-top: 3px;
}
.calliope-sp-wrap .calliope-sp-final-publish-bar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  margin-top: 16px;
  padding: 14px 0 0;
  border: 0;
  border-top: 1px solid var(--calliope-sp-border);
  border-radius: 0;
  background: transparent;
}

.calliope-sp-wrap .calliope-sp-platform-preview__footer {
  width: 100%;
  box-sizing: border-box;
}
.calliope-sp-wrap .calliope-sp-platform-preview__footer .calliope-sp-inline-publish-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
}

.calliope-sp-wrap .calliope-sp-final-publish-bar__status {
  flex: 1 1 auto;
  color: #b42318;
  font-size: 12px;
  font-weight: 700;
}
.calliope-sp-wrap .calliope-sp-final-publish-bar .calliope-sp-inline-publish-actions {
  margin: 0;
}
.calliope-sp-wrap .calliope-sp-platform-preview.is-loading {
  opacity: .86;
}

@media (max-width: 800px) {
  .calliope-sp-wrap .calliope-sp-platform-preview__head,
  .calliope-sp-wrap .calliope-sp-final-publish-bar {
    align-items: stretch;
    flex-direction: column;
  }
  .calliope-sp-wrap .calliope-sp-platform-preview__actions {
    justify-content: flex-start;
  }
  .calliope-sp-wrap .calliope-sp-platform-card__content {
    grid-template-columns: 1fr;
  }
  .calliope-sp-wrap .calliope-sp-platform-card__content h4,
  .calliope-sp-wrap .calliope-sp-platform-card__text,
  .calliope-sp-wrap .calliope-sp-platform-card__field,
  .calliope-sp-wrap .calliope-sp-platform-card__media {
    grid-column: 1;
    grid-row: auto;
  }
  .calliope-sp-wrap .calliope-sp-platform-card__media {
    margin-top: 4px;
  }
}

/* Free Step 9 — automatic UTM tracking. */
.calliope-sp-wrap .calliope-sp-settings-card--tracking {
  min-width: 0;
}
.calliope-sp-wrap .calliope-sp-tracking-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.calliope-sp-wrap .calliope-sp-short-links-setting {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px 16px;
  padding: 12px 14px;
  border: 1px solid #ddd2f2;
  border-radius: 10px;
  background: #fbf8ff;
}
.calliope-sp-wrap .calliope-sp-short-links-setting strong,
.calliope-sp-wrap .calliope-sp-short-links-setting p,
.calliope-sp-wrap .calliope-sp-short-links-setting small {
  display: block;
}
.calliope-sp-wrap .calliope-sp-short-links-setting p {
  margin: 3px 0 0;
  color: var(--calliope-sp-muted);
  font-size: 11px;
  line-height: 1.45;
}
.calliope-sp-wrap .calliope-sp-short-links-setting small {
  grid-column: 1 / -1;
  color: var(--calliope-sp-muted);
  line-height: 1.4;
}
.calliope-sp-wrap .calliope-sp-short-links-toggle {
  margin: 0;
  white-space: nowrap;
}
.calliope-sp-wrap .calliope-sp-tracking-grid .calliope-sp-field {
  min-width: 0;
}
.calliope-sp-wrap .calliope-sp-tracking-grid .calliope-sp-field-head {
  align-items: center;
}
.calliope-sp-wrap .calliope-sp-tracking-grid label code {
  margin-left: 5px;
  color: var(--calliope-sp-muted);
  font-size: 11px;
  font-weight: 600;
}
.calliope-sp-wrap .calliope-sp-tracking-token {
  flex: 0 0 auto;
  min-height: 26px;
  padding: 2px 8px;
  color: var(--calliope-sp-purple);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-tracking-preview {
  padding: 14px;
  border: 1px solid #ddd2f2;
  border-radius: 10px;
  background: #fbf8ff;
}
.calliope-sp-wrap .calliope-sp-tracking-preview__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 10px;
}
.calliope-sp-wrap .calliope-sp-tracking-preview__head > div strong,
.calliope-sp-wrap .calliope-sp-tracking-preview__head > div span {
  display: block;
}
.calliope-sp-wrap .calliope-sp-tracking-preview__head > div strong {
  color: var(--calliope-sp-heading);
  font-size: 13px;
}
.calliope-sp-wrap .calliope-sp-tracking-preview__head > div span,
.calliope-sp-wrap .calliope-sp-tracking-preview__head label span {
  margin-top: 3px;
  color: var(--calliope-sp-muted);
  font-size: 11px;
  line-height: 1.4;
}
.calliope-sp-wrap .calliope-sp-tracking-preview__head label {
  display: grid;
  flex: 0 0 190px;
  gap: 5px;
}
.calliope-sp-wrap .calliope-sp-tracking-preview code[data-tracking-example-url] {
  display: block;
  max-width: 100%;
  padding: 10px 12px;
  overflow-wrap: anywhere;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 8px;
  background: #fff;
  color: var(--calliope-sp-heading);
  font-size: 12px;
  line-height: 1.5;
}
.calliope-sp-wrap .calliope-sp-tracking-preview > p {
  margin: 8px 0 0;
  color: var(--calliope-sp-muted);
  font-size: 11px;
  line-height: 1.45;
}
.calliope-sp-wrap .calliope-sp-tracking-pro-teaser {
  margin-top: 0;
}
.calliope-sp-wrap .calliope-sp-platform-card__tracking {
  padding: 3px 7px;
  border-radius: 999px;
  background: #eef7ff;
  color: #175cd3;
  font-size: 10px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-platform-card__short-link {
  padding: 3px 7px;
  border-radius: 999px;
  background: #f2eaff;
  color: var(--calliope-sp-purple);
  font-size: 10px;
  font-weight: 800;
}

@media (min-width: 960px) {
  .calliope-sp-wrap .calliope-sp-settings-card--tracking {
    grid-column: 1 / -1;
    grid-row: 4;
    align-self: start;
  }
}

@media (max-width: 820px) {
  .calliope-sp-wrap .calliope-sp-tracking-grid {
    grid-template-columns: 1fr;
  }
  .calliope-sp-wrap .calliope-sp-short-links-setting {
    grid-template-columns: 1fr;
    align-items: start;
  }
  .calliope-sp-wrap .calliope-sp-short-links-setting small {
    grid-column: 1;
  }
  .calliope-sp-wrap .calliope-sp-tracking-preview__head {
    align-items: stretch;
    flex-direction: column;
  }
  .calliope-sp-wrap .calliope-sp-tracking-preview__head label {
    flex-basis: auto;
  }
}

/* Free Step 10 — failure-only email alerts. */
.calliope-sp-wrap .calliope-sp-settings-card--alerts {
  min-width: 0;
  gap: 12px;
  overflow: hidden;
  background: linear-gradient(180deg, #ffffff 0%, #fdfcff 100%);
  border-color: #ddd5ec;
}
.calliope-sp-wrap .calliope-sp-alerts-head {
  padding-bottom: 12px;
  border-bottom: 1px solid #eee9f5;
}
.calliope-sp-wrap .calliope-sp-alerts-form {
  gap: 12px;
}
.calliope-sp-wrap .calliope-sp-alerts-controls {
  display: grid;
  grid-template-columns: minmax(280px, .82fr) minmax(360px, 1.18fr);
  gap: 12px;
  align-items: stretch;
}
.calliope-sp-wrap .calliope-sp-alert-toggle,
.calliope-sp-wrap .calliope-sp-alert-email {
  min-width: 0;
  border: 1px solid var(--calliope-sp-border);
  border-radius: 12px;
  background: #fff;
}
.calliope-sp-wrap .calliope-sp-alert-toggle {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 78px;
  padding: 14px 16px;
  cursor: pointer;
  transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
}
.calliope-sp-wrap .calliope-sp-alert-toggle:hover {
  border-color: #cbb8e8;
  background: #fdfbff;
}
.calliope-sp-wrap .calliope-sp-alert-toggle:focus-within {
  border-color: var(--calliope-sp-purple);
  box-shadow: var(--calliope-sp-focus);
}
.calliope-sp-wrap .calliope-sp-alert-toggle__input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
.calliope-sp-wrap .calliope-sp-alert-toggle__switch {
  position: relative;
  flex: 0 0 42px;
  width: 42px;
  height: 24px;
  border-radius: 999px;
  background: #d9dde5;
  box-shadow: inset 0 0 0 1px rgba(24, 31, 45, .06);
  transition: background .16s ease, box-shadow .16s ease;
}
.calliope-sp-wrap .calliope-sp-alert-toggle__switch span {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(24, 31, 45, .22);
  transition: transform .16s ease;
}
.calliope-sp-wrap .calliope-sp-alert-toggle__input:checked + .calliope-sp-alert-toggle__switch {
  background: linear-gradient(135deg, #6f16c9, #d719d7);
  box-shadow: 0 4px 12px rgba(111, 22, 201, .2);
}
.calliope-sp-wrap .calliope-sp-alert-toggle__input:checked + .calliope-sp-alert-toggle__switch span {
  transform: translateX(18px);
}
.calliope-sp-wrap .calliope-sp-alert-toggle__copy {
  min-width: 0;
}
.calliope-sp-wrap .calliope-sp-alert-toggle__copy strong {
  display: block;
  color: var(--calliope-sp-heading);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.4;
}
.calliope-sp-wrap .calliope-sp-alert-email {
  display: flex;
  align-items: center;
  padding: 12px 14px;
  background: #fafbfc;
}
.calliope-sp-wrap .calliope-sp-alert-email .calliope-sp-field {
  width: 100%;
}
.calliope-sp-wrap .calliope-sp-alert-email .calliope-sp-field > label {
  margin-bottom: 6px;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-alert-email input[type="email"] {
  width: 100%;
  max-width: none;
  min-height: 40px;
  border-radius: 8px;
}
.calliope-sp-wrap .calliope-sp-alert-email .calliope-sp-hint {
  margin-top: 6px;
  line-height: 1.4;
}
.calliope-sp-wrap .calliope-sp-alerts-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 2px;
}
.calliope-sp-wrap .calliope-sp-alerts-footer .calliope-sp-muted {
  max-width: 760px;
  margin: 0;
  font-size: 11.5px;
  line-height: 1.45;
}
.calliope-sp-wrap .calliope-sp-alerts-footer .calliope-sp-settings-actions {
  flex: 0 0 auto;
}
.calliope-sp-wrap .calliope-sp-alerts-footer .button-primary {
  min-width: 150px;
}
@media (min-width: 960px) {
  .calliope-sp-wrap .calliope-sp-settings-card--alerts {
    grid-column: 1 / -1;
    grid-row: 5;
    align-self: start;
  }
}
@media (max-width: 820px) {
  .calliope-sp-wrap .calliope-sp-alerts-controls {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 640px) {
  .calliope-sp-wrap .calliope-sp-alerts-footer {
    align-items: stretch;
    flex-direction: column;
  }
  .calliope-sp-wrap .calliope-sp-alerts-footer .button-primary {
    width: 100%;
  }
}


/* Dashboard overview — 1.5.56 */
.calliope-sp-wrap .calliope-sp-dashboard {
  display: grid;
  gap: 18px;
}
.calliope-sp-wrap .calliope-sp-dashboard-health {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 20px 22px;
  border: 1px solid #d9e1ef;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(32, 50, 89, .05);
}
.calliope-sp-wrap .calliope-sp-dashboard-health.is-healthy { border-left: 4px solid #1aa36f; }
.calliope-sp-wrap .calliope-sp-dashboard-health.is-warning { border-left: 4px solid #d89b16; }
.calliope-sp-wrap .calliope-sp-dashboard-health.is-neutral { border-left: 4px solid #7b5ce7; }
.calliope-sp-wrap .calliope-sp-dashboard-health__icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: #f2f5fb;
  color: #304466;
}
.calliope-sp-wrap .calliope-sp-dashboard-health.is-healthy .calliope-sp-dashboard-health__icon { background: #eaf8f2; color: #11865b; }
.calliope-sp-wrap .calliope-sp-dashboard-health.is-warning .calliope-sp-dashboard-health__icon { background: #fff7e8; color: #b47800; }
.calliope-sp-wrap .calliope-sp-dashboard-health__icon .dashicons { width: 24px; height: 24px; font-size: 24px; }
.calliope-sp-wrap .calliope-sp-dashboard-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 4px;
  color: #65738e;
  font-size: 11px;
  line-height: 1.2;
  font-weight: 800;
  letter-spacing: .065em;
  text-transform: uppercase;
}
.calliope-sp-wrap .calliope-sp-dashboard-health h2,
.calliope-sp-wrap .calliope-sp-dashboard-section h3,
.calliope-sp-wrap .calliope-sp-dashboard-pro-live h3,
.calliope-sp-wrap .calliope-sp-dashboard-pro-teaser h3 {
  margin: 0;
  color: #24385f;
}
.calliope-sp-wrap .calliope-sp-dashboard-health h2 { font-size: 22px; line-height: 1.25; }
.calliope-sp-wrap .calliope-sp-dashboard-health p,
.calliope-sp-wrap .calliope-sp-dashboard-pro-live p,
.calliope-sp-wrap .calliope-sp-dashboard-pro-teaser p { margin: 5px 0 0; color: #64718a; }
.calliope-sp-wrap .calliope-sp-dashboard-grid {
  display: grid;
  gap: 18px;
}
.calliope-sp-wrap .calliope-sp-dashboard-grid--top { grid-template-columns: minmax(0, 1.15fr) minmax(360px, .85fr); }
.calliope-sp-wrap .calliope-sp-dashboard-grid--lower { grid-template-columns: minmax(0, 1.35fr) minmax(330px, .65fr); }
.calliope-sp-wrap .calliope-sp-dashboard-section,
.calliope-sp-wrap .calliope-sp-dashboard-pro-live,
.calliope-sp-wrap .calliope-sp-dashboard-pro-teaser { margin: 0; padding: 20px 22px; }
.calliope-sp-wrap .calliope-sp-dashboard-section__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}
.calliope-sp-wrap .calliope-sp-dashboard-section__head h3 { font-size: 17px; line-height: 1.3; }
.calliope-sp-wrap .calliope-sp-dashboard-section__head > a,
.calliope-sp-wrap .calliope-sp-dashboard-config__actions a {
  color: #6d24d8;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.calliope-sp-wrap .calliope-sp-dashboard-section__head > a:hover,
.calliope-sp-wrap .calliope-sp-dashboard-section__head > a:focus,
.calliope-sp-wrap .calliope-sp-dashboard-config__actions a:hover,
.calliope-sp-wrap .calliope-sp-dashboard-config__actions a:focus { color: #4d16a8; text-decoration: underline; }
.calliope-sp-wrap .calliope-sp-dashboard-count {
  min-width: 28px;
  height: 28px;
  padding: 0 8px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: #f0f3f8;
  color: #3a4c6c;
  font-weight: 800;
}
.calliope-sp-wrap .calliope-sp-dashboard-count.is-warning { background: #fff3db; color: #985f00; }
.calliope-sp-wrap .calliope-sp-dashboard-attention-list,
.calliope-sp-wrap .calliope-sp-dashboard-recent-list { display: grid; gap: 10px; }
.calliope-sp-wrap .calliope-sp-dashboard-attention-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 11px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid #edf0f5;
}
.calliope-sp-wrap .calliope-sp-dashboard-attention-item:first-child { border-top: 0; padding-top: 0; }
.calliope-sp-wrap .calliope-sp-dashboard-attention-item > .dashicons { color: #c48608; }
.calliope-sp-wrap .calliope-sp-dashboard-attention-item strong { display: block; color: #2d3e5f; }
.calliope-sp-wrap .calliope-sp-dashboard-attention-item p { margin: 3px 0 0; color: #6f7a90; font-size: 13px; }
.calliope-sp-wrap .calliope-sp-dashboard-attention-item a { color: #6d24d8; font-weight: 700; text-decoration: none; white-space: nowrap; }
.calliope-sp-wrap .calliope-sp-dashboard-clear {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 78px;
  padding: 14px 16px;
  border-radius: 11px;
  background: #f2faf6;
}
.calliope-sp-wrap .calliope-sp-dashboard-clear.is-neutral { background: #f6f7fa; }
.calliope-sp-wrap .calliope-sp-dashboard-clear .dashicons { color: #159162; font-size: 24px; width: 24px; height: 24px; }
.calliope-sp-wrap .calliope-sp-dashboard-clear.is-neutral .dashicons { color: #75829a; }
.calliope-sp-wrap .calliope-sp-dashboard-clear strong { display: block; color: #2c3f60; }
.calliope-sp-wrap .calliope-sp-dashboard-clear p { margin: 3px 0 0; color: #718099; }
.calliope-sp-wrap .calliope-sp-dashboard-activity__summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.calliope-sp-wrap .calliope-sp-dashboard-activity__summary > div {
  min-width: 0;
  padding: 11px 12px;
  border: 1px solid #e5eaf2;
  border-radius: 10px;
  background: #fafbfe;
}
.calliope-sp-wrap .calliope-sp-dashboard-activity__summary strong { display: block; overflow: hidden; color: #2a3f64; font-size: 20px; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }
.calliope-sp-wrap .calliope-sp-dashboard-activity__summary span { display: block; margin-top: 3px; color: #77839a; font-size: 11px; font-weight: 700; text-transform: uppercase; }
.calliope-sp-wrap .calliope-sp-dashboard-spark {
  height: 112px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
  align-items: end;
  padding: 10px 2px 0;
  border-top: 1px solid #edf0f5;
}
.calliope-sp-wrap .calliope-sp-dashboard-spark__day { height: 100%; display: grid; grid-template-rows: 1fr auto; gap: 5px; align-items: end; text-align: center; }
.calliope-sp-wrap .calliope-sp-dashboard-spark__bar {
  position: relative;
  width: min(28px, 72%);
  height: var(--calliope-sp-bar-height, 3%);
  min-height: 3px;
  justify-self: center;
  overflow: hidden;
  border-radius: 6px 6px 3px 3px;
  background: #28a571;
}
.calliope-sp-wrap .calliope-sp-dashboard-spark__bar i {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--calliope-sp-fail-height, 0%);
  background: #d94b4b;
}
.calliope-sp-wrap .calliope-sp-dashboard-spark__day small { color: #8691a5; font-size: 10px; white-space: nowrap; }
.calliope-sp-wrap .calliope-sp-dashboard-recent-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  padding: 12px 0;
  border-top: 1px solid #edf0f5;
}
.calliope-sp-wrap .calliope-sp-dashboard-recent-item:first-child { border-top: 0; padding-top: 0; }
.calliope-sp-wrap .calliope-sp-dashboard-recent-item__dot { width: 9px; height: 9px; border-radius: 50%; background: #1da36d; }
.calliope-sp-wrap .calliope-sp-dashboard-recent-item.is-warning .calliope-sp-dashboard-recent-item__dot { background: #d89b16; }
.calliope-sp-wrap .calliope-sp-dashboard-recent-item.is-pending .calliope-sp-dashboard-recent-item__dot { background: #7b87a0; }
.calliope-sp-wrap .calliope-sp-dashboard-recent-item__body strong { display: block; color: #2b3f62; }
.calliope-sp-wrap .calliope-sp-dashboard-recent-item__body span { display: block; margin-top: 3px; color: #77839a; font-size: 12px; }
.calliope-sp-wrap .calliope-sp-dashboard-recent-item time { color: #7c889d; font-size: 12px; white-space: nowrap; }
.calliope-sp-wrap .calliope-sp-dashboard-config__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 0;
  border-top: 1px solid #edf0f5;
  color: #53617a;
}
.calliope-sp-wrap .calliope-sp-dashboard-config__row:first-of-type { border-top: 0; padding-top: 0; }
.calliope-sp-wrap .calliope-sp-dashboard-config__row strong { color: #2b3e61; }
.calliope-sp-wrap .calliope-sp-dashboard-config__row strong.is-on { color: #13885c; }
.calliope-sp-wrap .calliope-sp-dashboard-config__row strong.is-off { color: #8a6470; }
.calliope-sp-wrap .calliope-sp-dashboard-network-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 3px 0 12px; }
.calliope-sp-wrap .calliope-sp-dashboard-network-chips span {
  padding: 4px 8px;
  border-radius: 999px;
  background: #f1f4f9;
  color: #50617f;
  font-size: 11px;
  font-weight: 700;
}
.calliope-sp-wrap .calliope-sp-dashboard-config__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 13px; padding-top: 13px; border-top: 1px solid #edf0f5; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-teaser,
.calliope-sp-wrap .calliope-sp-dashboard-pro-live {
  display: grid;
  gap: 16px;
  border-color: #e1d5f7;
  background: linear-gradient(135deg, #fff 0%, #fbf8ff 100%);
}
.calliope-sp-wrap .calliope-sp-dashboard-pro-teaser { grid-template-columns: minmax(0, 1.25fr) minmax(320px, .75fr) auto; align-items: center; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-teaser__features { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-teaser__features > span { display: flex; align-items: center; gap: 7px; padding: 8px 10px; border: 1px dashed #d9c9f4; border-radius: 9px; color: #6b5a83; font-size: 12px; font-weight: 700; background: rgba(255,255,255,.72); }
.calliope-sp-wrap .calliope-sp-dashboard-pro-teaser__features .dashicons { color: #7b2bd2; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-live .calliope-sp-dashboard-section__head { margin-bottom: 0; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-metrics > div { padding: 13px 14px; border: 1px solid #e7def5; border-radius: 10px; background: rgba(255,255,255,.78); }
.calliope-sp-wrap .calliope-sp-dashboard-pro-metrics > div.is-warning { border-color: #efd59f; background: #fffaf0; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-metrics strong { display: block; color: #2d3d5f; font-size: 22px; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-metrics span { display: block; margin-top: 3px; color: #6f7890; font-size: 12px; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-next { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 13px 14px; border: 1px solid #e7def5; border-radius: 10px; background: rgba(255,255,255,.78); }
.calliope-sp-wrap .calliope-sp-dashboard-pro-next > div > span,
.calliope-sp-wrap .calliope-sp-dashboard-pro-next > div > strong,
.calliope-sp-wrap .calliope-sp-dashboard-pro-next > div > small { display: block; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-next > div > span { color: #7a6b8e; font-size: 11px; font-weight: 800; text-transform: uppercase; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-next > div > strong { margin-top: 3px; color: #2d3e60; }
.calliope-sp-wrap .calliope-sp-dashboard-pro-next > div > small { margin-top: 2px; color: #7a8497; }
.calliope-sp-wrap .calliope-sp-dashboard-overdue { display: inline-flex; align-items: center; gap: 6px; color: #a56a00; font-weight: 700; white-space: nowrap; }

@media (max-width: 1180px) {
  .calliope-sp-wrap .calliope-sp-dashboard-grid--top,
  .calliope-sp-wrap .calliope-sp-dashboard-grid--lower { grid-template-columns: 1fr; }
  .calliope-sp-wrap .calliope-sp-dashboard-pro-teaser { grid-template-columns: 1fr; }
  .calliope-sp-wrap .calliope-sp-dashboard-pro-teaser > .button { justify-self: start; }
}
@media (max-width: 782px) {
  .calliope-sp-wrap .calliope-sp-dashboard-health { grid-template-columns: auto minmax(0, 1fr); }
  .calliope-sp-wrap .calliope-sp-dashboard-health > .button { grid-column: 1 / -1; width: 100%; text-align: center; }
  .calliope-sp-wrap .calliope-sp-dashboard-activity__summary,
  .calliope-sp-wrap .calliope-sp-dashboard-pro-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .calliope-sp-wrap .calliope-sp-dashboard-attention-item,
  .calliope-sp-wrap .calliope-sp-dashboard-recent-item { grid-template-columns: auto minmax(0, 1fr); }
  .calliope-sp-wrap .calliope-sp-dashboard-attention-item > a,
  .calliope-sp-wrap .calliope-sp-dashboard-recent-item > time { grid-column: 2; }
  .calliope-sp-wrap .calliope-sp-dashboard-spark__day small { font-size: 9px; }
}
@media (max-width: 520px) {
  .calliope-sp-wrap .calliope-sp-dashboard-health,
  .calliope-sp-wrap .calliope-sp-dashboard-section,
  .calliope-sp-wrap .calliope-sp-dashboard-pro-live,
  .calliope-sp-wrap .calliope-sp-dashboard-pro-teaser { padding: 16px; }
  .calliope-sp-wrap .calliope-sp-dashboard-activity__summary,
  .calliope-sp-wrap .calliope-sp-dashboard-pro-metrics { grid-template-columns: 1fr; }
  .calliope-sp-wrap .calliope-sp-dashboard-section__head { align-items: flex-start; }
  .calliope-sp-wrap .calliope-sp-dashboard-pro-next { align-items: flex-start; flex-direction: column; }
}
.calliope-sp-wrap .calliope-sp-dashboard-grid--top.is-clear { grid-template-columns: 1fr; }


/* 1.5.57: compact two-column Publisher composer. */
.calliope-sp-wrap #calliope_sp_publish_form {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr);
  gap: 16px 20px;
  align-items: start;
}

/* Keep publication type outside the switchable composers, but visually place it in the right rail. */
.calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout {
  grid-column: 2;
  grid-row: 1;
  display: block;
  min-width: 0;
  width: 100%;
  margin: 0;
  padding: 18px;
  border: 1px solid var(--calliope-sp-border);
  border-radius: var(--calliope-sp-radius);
  background: var(--calliope-sp-surface);
  box-shadow: var(--calliope-sp-shadow-soft);
}

.calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout > .calliope-spp-publication-type {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
  width: 100%;
  margin: 0;
}

.calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout .calliope-spp-publication-type legend {
  margin: 0 0 12px;
  font-size: 15px;
  line-height: 1.35;
  color: var(--calliope-sp-heading);
}

.calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout .calliope-spp-publication-type label,
.calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout .calliope-spp-publication-type__locked-option {
  width: 100%;
  min-width: 0;
  flex: none;
  padding: 13px 14px;
}

.calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout .calliope-spp-publication-type label:not(.is-selected) {
  background: var(--calliope-sp-surface-soft);
}

.calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout .calliope-spp-publication-type label:hover {
  border-color: var(--calliope-sp-border-strong);
}

.calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout .calliope-spp-publication-type__actions {
  display: flex;
  min-height: 0;
  margin: 9px 0 0;
  justify-content: flex-start;
}

.calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout .calliope-spp-publication-type__cta-button {
  width: 100%;
  justify-content: center;
}

/* Let the standard composer's first cards participate in the form grid. */
.calliope-sp-wrap #calliope-sp-standard-composer {
  display: contents;
}

.calliope-sp-wrap #calliope-sp-standard-composer[hidden] {
  display: none !important;
}

.calliope-sp-wrap #calliope-sp-standard-composer > .calliope-sp-composer-grid {
  display: contents;
}

.calliope-sp-wrap #calliope-sp-standard-composer .calliope-sp-content-card {
  grid-column: 1;
  grid-row: 1 / span 2;
  min-width: 0;
}

.calliope-sp-wrap #calliope-sp-standard-composer .calliope-sp-image-card {
  grid-column: 2;
  grid-row: 2;
  min-width: 0;
  margin: 0;
}

.calliope-sp-wrap #calliope-sp-standard-composer > .calliope-sp-composer-section {
  grid-column: 1 / -1;
  min-width: 0;
  margin-top: 0;
}

.calliope-sp-wrap #calliope-spp-video-composer {
  grid-column: 1 / -1;
  min-width: 0;
}

/* Video mode uses the full Publisher width so the right-rail publication-type card
   never leaves an empty desktop column above the video composer. */
.calliope-sp-wrap #calliope_sp_publish_form.is-video-publication {
  grid-template-columns: 1fr;
}
.calliope-sp-wrap #calliope_sp_publish_form.is-video-publication > .calliope-sp-publication-type-layout,
.calliope-sp-wrap #calliope_sp_publish_form.is-video-publication > #calliope-spp-video-composer {
  grid-column: 1;
  grid-row: auto;
}
.calliope-sp-wrap #calliope_sp_publish_form.is-video-publication > .calliope-sp-publication-type-layout > .calliope-spp-publication-type {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.calliope-sp-wrap #calliope_sp_publish_form.is-video-publication > .calliope-sp-publication-type-layout .calliope-spp-publication-type legend {
  grid-column: 1 / -1;
}
@media (max-width: 782px) {
  .calliope-sp-wrap #calliope_sp_publish_form.is-video-publication > .calliope-sp-publication-type-layout > .calliope-spp-publication-type {
    grid-template-columns: 1fr;
  }
}

/* Keep both Publisher columns flush even when their content lengths differ. */
@media (min-width: 1081px) {
  .calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout,
  .calliope-sp-wrap #calliope-sp-standard-composer .calliope-sp-content-card,
  .calliope-sp-wrap #calliope-sp-standard-composer .calliope-sp-image-card {
    align-self: stretch;
  }
}

@media (max-width: 1080px) {
  .calliope-sp-wrap #calliope_sp_publish_form {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout,
  .calliope-sp-wrap #calliope-sp-standard-composer .calliope-sp-content-card,
  .calliope-sp-wrap #calliope-sp-standard-composer .calliope-sp-image-card,
  .calliope-sp-wrap #calliope-sp-standard-composer > .calliope-sp-composer-section,
  .calliope-sp-wrap #calliope-spp-video-composer {
    grid-column: 1;
    grid-row: auto;
  }

  /* On compact screens Content comes first, then publication type and Media. */
  .calliope-sp-wrap #calliope-sp-standard-composer .calliope-sp-content-card { order: 1; }
  .calliope-sp-wrap #calliope_sp_publish_form > .calliope-sp-publication-type-layout { order: 2; }
  .calliope-sp-wrap #calliope-sp-standard-composer .calliope-sp-image-card { order: 3; }
  .calliope-sp-wrap #calliope-sp-standard-composer > .calliope-sp-composer-section { order: 4; }
  .calliope-sp-wrap #calliope-sp-standard-composer > .calliope-sp-platform-preview-section { order: 5; }
  .calliope-sp-wrap #calliope-spp-video-composer { order: 6; }
}

/* Step 7.1 — GA4 attribution help */
.calliope-sp-wrap .calliope-sp-ga4-help{display:grid;gap:12px;margin-top:14px;padding:15px 16px;border:1px solid var(--calliope-sp-border);border-radius:10px;background:#faf9fd}
.calliope-sp-wrap .calliope-sp-ga4-help>div:first-child p,.calliope-sp-wrap .calliope-sp-ga4-help__note{margin:4px 0 0;color:var(--calliope-sp-muted);line-height:1.5}
.calliope-sp-wrap .calliope-sp-ga4-help__path{display:flex;flex-wrap:wrap;gap:6px 10px;align-items:center}
.calliope-sp-wrap .calliope-sp-ga4-help__dimensions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.calliope-sp-wrap .calliope-sp-ga4-help__dimensions>div{display:grid;gap:5px;padding:10px 12px;border:1px solid #e3dfeb;border-radius:8px;background:#fff}
.calliope-sp-wrap .calliope-sp-ga4-help__dimensions span{font-size:12px;font-weight:650;color:var(--calliope-sp-muted)}
.calliope-sp-wrap .calliope-sp-ga4-help__dimensions code{overflow-wrap:anywhere;white-space:normal}
@media(max-width:782px){.calliope-sp-wrap .calliope-sp-ga4-help__dimensions{grid-template-columns:1fr}}

/* Pro connection brand marks: keep complex logos optically aligned with the standard 18/28px icon boxes. */
.calliope-sp-wrap .calliope-sp-net-tab.net-custom_webhook .calliope-sp-network-icon svg {
  width: 16px !important;
  height: 16px !important;
  max-width: 16px !important;
  max-height: 16px !important;
  overflow: visible;
}
.calliope-sp-wrap .calliope-sp-connection-shell.net-custom_webhook .calliope-sp-connection-logo > .calliope-sp-network-icon,
.calliope-sp-wrap .calliope-sp-connection-shell.net-custom_webhook .calliope-sp-connection-logo > svg {
  width: 24px !important;
  height: 24px !important;
  max-width: 24px !important;
  max-height: 24px !important;
  overflow: visible;
}
.calliope-sp-wrap .calliope-sp-connection-shell.net-custom_webhook .calliope-sp-connection-logo .calliope-sp-network-icon svg {
  width: 24px !important;
  height: 24px !important;
  max-width: 24px !important;
  max-height: 24px !important;
}


/* Connection logo hard-fix: exact assets + forced dimensions. Keep this block last. */
.calliope-sp-wrap .calliope-sp-net-tab.net-wordpress_remote .calliope-sp-network-icon,
.calliope-sp-wrap .calliope-sp-net-tab.net-custom_webhook .calliope-sp-network-icon {
  display:inline-block !important;
  width:18px !important;
  height:18px !important;
  min-width:18px !important;
  min-height:18px !important;
  max-width:18px !important;
  max-height:18px !important;
  flex:0 0 18px !important;
  margin:0 !important;
  padding:0 !important;
  overflow:visible !important;
  background-position:center !important;
  background-repeat:no-repeat !important;
  background-size:contain !important;
}
.calliope-sp-wrap .calliope-sp-net-tab.net-wordpress_remote .calliope-sp-network-icon {background-image:url('../images/wordpress-remote-mark.svg') !important;}
.calliope-sp-wrap .calliope-sp-net-tab.net-custom_webhook .calliope-sp-network-icon {background-image:url('../images/custom-webhook-mark.svg') !important;}
.calliope-sp-wrap .calliope-sp-net-tab.net-wordpress_remote .calliope-sp-network-icon svg,
.calliope-sp-wrap .calliope-sp-net-tab.net-custom_webhook .calliope-sp-network-icon svg {display:none !important;}

.calliope-sp-wrap .calliope-sp-connection-shell.net-wordpress_remote .calliope-sp-connection-logo > .calliope-sp-network-icon,
.calliope-sp-wrap .calliope-sp-connection-shell.net-custom_webhook .calliope-sp-connection-logo > .calliope-sp-network-icon {
  display:block !important;
  width:30px !important;
  height:30px !important;
  min-width:30px !important;
  min-height:30px !important;
  max-width:30px !important;
  max-height:30px !important;
  flex:0 0 30px !important;
  margin:0 !important;
  padding:0 !important;
  overflow:visible !important;
  background-position:center !important;
  background-repeat:no-repeat !important;
  background-size:contain !important;
}
.calliope-sp-wrap .calliope-sp-connection-shell.net-wordpress_remote .calliope-sp-connection-logo > .calliope-sp-network-icon {background-image:url('../images/wordpress-remote-mark.svg') !important;}
.calliope-sp-wrap .calliope-sp-connection-shell.net-custom_webhook .calliope-sp-connection-logo > .calliope-sp-network-icon {background-image:url('../images/custom-webhook-mark.svg') !important;}
.calliope-sp-wrap .calliope-sp-connection-shell.net-wordpress_remote .calliope-sp-connection-logo .calliope-sp-network-icon svg,
.calliope-sp-wrap .calliope-sp-connection-shell.net-custom_webhook .calliope-sp-connection-logo .calliope-sp-network-icon svg {display:none !important;}

.calliope-sp-wrap .calliope-sp-net-tab.net-wordpress_remote.is-disconnected .calliope-sp-network-icon,
.calliope-sp-wrap .calliope-sp-net-tab.net-custom_webhook.is-disconnected .calliope-sp-network-icon,
.calliope-sp-wrap .calliope-sp-connection-shell.net-wordpress_remote.is-disconnected .calliope-sp-connection-logo > .calliope-sp-network-icon,
.calliope-sp-wrap .calliope-sp-connection-shell.net-custom_webhook.is-disconnected .calliope-sp-connection-logo > .calliope-sp-network-icon {
  filter:grayscale(1) saturate(0) opacity(.58) !important;
}
.calliope-sp-wrap .calliope-sp-net-tab.net-wordpress_remote.is-connected .calliope-sp-network-icon,
.calliope-sp-wrap .calliope-sp-net-tab.net-custom_webhook.is-connected .calliope-sp-network-icon,
.calliope-sp-wrap .calliope-sp-connection-shell.net-wordpress_remote.is-connected .calliope-sp-connection-logo > .calliope-sp-network-icon,
.calliope-sp-wrap .calliope-sp-connection-shell.net-custom_webhook.is-connected .calliope-sp-connection-logo > .calliope-sp-network-icon {
  filter:none !important;
  opacity:1 !important;
}
.calliope-sp-wrap .calliope-sp-connection-shell.net-wordpress_remote .calliope-sp-connection-logo,
.calliope-sp-wrap .calliope-sp-connection-shell.net-custom_webhook .calliope-sp-connection-logo {
  overflow:visible !important;
}

/* Dashboard refresh — unified Free/Pro overview. */
.calliope-sp-wrap .calliope-sp-dashboard-health__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}
.calliope-sp-wrap .calliope-sp-dashboard-grid--operations {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.calliope-sp-wrap .calliope-sp-dashboard-activity__summary {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.calliope-sp-wrap .calliope-sp-dashboard-next__main {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-height: 82px;
  padding: 14px;
  border: 1px solid #e5eaf2;
  border-radius: 11px;
  background: #fafbfe;
}
.calliope-sp-wrap .calliope-sp-dashboard-next__main > .dashicons {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #eee8fb;
  color: #6d24d8;
  font-size: 20px;
}
.calliope-sp-wrap .calliope-sp-dashboard-next__main strong,
.calliope-sp-wrap .calliope-sp-dashboard-next__main time,
.calliope-sp-wrap .calliope-sp-dashboard-next__main small { display: block; }
.calliope-sp-wrap .calliope-sp-dashboard-next__main strong { color: #293d61; font-size: 15px; }
.calliope-sp-wrap .calliope-sp-dashboard-next__main time { margin-top: 4px; color: #596a85; font-weight: 700; }
.calliope-sp-wrap .calliope-sp-dashboard-next__main small { margin-top: 3px; color: #7b879c; }
.calliope-sp-wrap .calliope-sp-dashboard-mini-metrics,
.calliope-sp-wrap .calliope-sp-dashboard-destination-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}
.calliope-sp-wrap .calliope-sp-dashboard-mini-metrics > div,
.calliope-sp-wrap .calliope-sp-dashboard-destination-stats > div {
  padding: 9px 10px;
  border: 1px solid #e5eaf2;
  border-radius: 9px;
  background: #fff;
}
.calliope-sp-wrap .calliope-sp-dashboard-mini-metrics strong,
.calliope-sp-wrap .calliope-sp-dashboard-destination-stats strong {
  display: block;
  color: #2d4062;
  font-size: 18px;
}
.calliope-sp-wrap .calliope-sp-dashboard-mini-metrics span,
.calliope-sp-wrap .calliope-sp-dashboard-destination-stats span {
  display: block;
  margin-top: 2px;
  color: #77839a;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .02em;
  text-transform: uppercase;
}
.calliope-sp-wrap .calliope-sp-dashboard-mini-metrics > .is-warning,
.calliope-sp-wrap .calliope-sp-dashboard-destination-stats > .is-warning {
  border-color: #efd59f;
  background: #fffaf0;
}
.calliope-sp-wrap .calliope-sp-dashboard-destination-stats > .is-ready {
  border-color: #cde9dc;
  background: #f5fbf8;
}
.calliope-sp-wrap .calliope-sp-dashboard-automation-count {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: -3px 0 10px;
}
.calliope-sp-wrap .calliope-sp-dashboard-automation-count strong { color: #2c3e61; font-size: 24px; }
.calliope-sp-wrap .calliope-sp-dashboard-automation-count span { color: #718099; font-size: 12px; font-weight: 700; }
.calliope-sp-wrap .calliope-sp-dashboard-automation-list { display: grid; gap: 0; }
.calliope-sp-wrap .calliope-sp-dashboard-automation-list article {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px 0;
  border-top: 1px solid #edf0f5;
}
.calliope-sp-wrap .calliope-sp-dashboard-automation-list article:first-child { border-top: 0; }
.calliope-sp-wrap .calliope-sp-dashboard-automation-list strong { display: block; color: #2b3f62; }
.calliope-sp-wrap .calliope-sp-dashboard-automation-list span { display: block; margin-top: 3px; color: #77839a; font-size: 12px; }
.calliope-sp-wrap .calliope-sp-dashboard-automation-list time { color: #6b7890; font-size: 12px; font-weight: 700; white-space: nowrap; }
.calliope-sp-wrap .calliope-sp-dashboard-network-chips.is-warning span {
  background: #fff4df;
  color: #986200;
}
.calliope-sp-wrap .calliope-sp-dashboard-destinations .calliope-sp-dashboard-network-chips {
  padding-top: 12px;
  padding-bottom: 0;
}

@media (max-width: 1180px) {
  .calliope-sp-wrap .calliope-sp-dashboard-grid--operations { grid-template-columns: 1fr; }
}
@media (max-width: 782px) {
  .calliope-sp-wrap .calliope-sp-dashboard-health__actions {
    grid-column: 1 / -1;
    justify-content: stretch;
  }
  .calliope-sp-wrap .calliope-sp-dashboard-health__actions .button { flex: 1 1 auto; text-align: center; }
  .calliope-sp-wrap .calliope-sp-dashboard-activity__summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .calliope-sp-wrap .calliope-sp-dashboard-automation-list article { grid-template-columns: auto minmax(0, 1fr); }
  .calliope-sp-wrap .calliope-sp-dashboard-automation-list time { grid-column: 2; }
}
@media (max-width: 520px) {
  .calliope-sp-wrap .calliope-sp-dashboard-activity__summary,
  .calliope-sp-wrap .calliope-sp-dashboard-mini-metrics,
  .calliope-sp-wrap .calliope-sp-dashboard-destination-stats { grid-template-columns: 1fr; }
}

/* Analytics: when Pro is active this element is only a zero-height server-side mount point.
 * The Free analytics remain visible and Pro appends its advanced layer below without replacing them. */
.calliope-sp-wrap .calliope-sp-analytics-pro.calliope-sp-analytics-pro--mount {
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}
