/*
 * Future Island Intelligence Suite v1.5.0-rc.2
 * Premium UI Rescue + Social Run Reliability RC.
 * Scoped design-system layer: no broad WP admin reset, no global framework.
 */
.ves-wrap.fi-shell,
.ves-wrap.fiis-membership-screen,
.ves-wrap.fiis-provider-settings,
.ves-wrap .fi-signal-room,
.fiis-membership-screen,
.fiis-signal-room {
  --fi-bg: #f4f1ea;
  --fi-surface: #fffaf1;
  --fi-surface-soft: #f8f4ea;
  --fi-ink: #111111;
  --fi-muted: #6f6a60;
  --fi-blue: #2458d3;
  --fi-blue-soft: #e7edff;
  --fi-sand: #d8c4a3;
  --fi-lime: #c8ff4d;
  --fi-orange: #ff5a2f;
  --fi-border: rgba(17,17,17,.12);
  --fi-radius-sm: 8px;
  --fi-radius-md: 14px;
  --fi-radius-lg: 22px;
  --fi-shadow-soft: 0 16px 40px rgba(17,17,17,.08);
  color: var(--fi-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* Future-facing class contracts used by reports/tests and current markup. */
.fi-shell,
.fi-sidebar,
.fi-topbar,
.fi-command-canvas,
.fi-signal-room,
.fi-evidence-drawer,
.fi-run-timeline,
.fi-decision-report,
.fi-membership-panel,
.fi-credit-ledger,
.fi-action-rail { box-sizing: border-box; }

.ves-wrap.fi-shell.ves-light-suite {
  background: var(--fi-bg) !important;
  grid-template-columns: 260px minmax(0, 1fr) !important;
  min-height: min(100vh, var(--ves-suite-height, 920px));
}

.ves-wrap.fi-shell .fi-sidebar,
.ves-wrap.fi-shell .ves-sidebar.fi-sidebar {
  width: 260px !important;
  background: linear-gradient(180deg, var(--fi-surface) 0%, var(--fi-surface-soft) 100%) !important;
  border-right: 1px solid var(--fi-border) !important;
  box-shadow: none !important;
  padding: 18px 14px !important;
}

.ves-wrap.fi-shell .ves-workspace-switcher {
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  padding: 4px 2px 18px !important;
}

.ves-wrap.fi-shell .ves-logo {
  background: var(--fi-ink) !important;
  color: var(--fi-surface) !important;
  border-radius: 10px !important;
  box-shadow: none !important;
  letter-spacing: .05em;
}

.ves-wrap.fi-shell .ves-workspace-text strong {
  color: var(--fi-ink) !important;
  font-size: 13px !important;
  letter-spacing: .02em;
}

.ves-wrap.fi-shell .ves-workspace-meta,
.ves-wrap.fi-shell .ves-current-project-pill {
  color: var(--fi-muted) !important;
  font-size: 11px !important;
}

.ves-wrap.fi-shell .ves-sidebar-section-label {
  color: rgba(17,17,17,.52) !important;
  font-size: 10px !important;
  font-weight: 750 !important;
  letter-spacing: .16em !important;
  text-transform: uppercase;
  margin: 20px 10px 7px !important;
}

.ves-wrap.fi-shell .ves-nav-group { gap: 2px !important; }
.ves-wrap.fi-shell .ves-nav-item {
  min-height: 34px !important;
  border: 0 !important;
  border-radius: 12px !important;
  background: transparent !important;
  color: rgba(17,17,17,.72) !important;
  font-size: 13px !important;
  font-weight: 650 !important;
  letter-spacing: -.01em;
  padding: 8px 10px !important;
}
.ves-wrap.fi-shell .ves-nav-item:hover,
.ves-wrap.fi-shell .ves-nav-item:focus-visible {
  background: rgba(17,17,17,.05) !important;
  color: var(--fi-ink) !important;
  outline: 2px solid rgba(36,88,211,.25) !important;
  outline-offset: 2px;
}
.ves-wrap.fi-shell .ves-nav-item.is-active {
  background: var(--fi-ink) !important;
  color: var(--fi-surface) !important;
  box-shadow: none !important;
}
.ves-wrap.fi-shell .ves-nav-item.is-active .ves-nav-ico-wrap {
  background: var(--fi-blue) !important;
  color: #fff !important;
}
.ves-wrap.fi-shell .ves-nav-ico-wrap {
  width: 26px !important;
  height: 26px !important;
  border-radius: 9px !important;
  background: rgba(17,17,17,.06) !important;
}
.ves-wrap.fi-shell .ves-nav-soon {
  border: 0 !important;
  background: transparent !important;
  color: rgba(17,17,17,.38) !important;
  font-size: 9px !important;
  padding: 0 !important;
}

.ves-wrap.fi-shell .ves-sidebar-memory,
.ves-wrap.fi-shell .ves-sidebar-foot {
  background: transparent !important;
  border: 0 !important;
}
.ves-wrap.fi-shell .ves-sidebar-credits {
  margin-top: 18px !important;
  background: rgba(17,17,17,.045) !important;
  border: 1px solid rgba(17,17,17,.09) !important;
  border-radius: 14px !important;
  color: var(--fi-ink) !important;
}
.ves-wrap.fi-shell .ves-sidebar-credits-bar { background: rgba(17,17,17,.10) !important; }
.ves-wrap.fi-shell .ves-sidebar-credits-bar span { background: var(--fi-blue) !important; }

.ves-wrap.fi-shell .fi-topbar,
.ves-wrap.fi-shell .ves-topbar.fi-topbar {
  background: rgba(244,241,234,.86) !important;
  border-bottom: 1px solid var(--fi-border) !important;
  backdrop-filter: blur(18px);
  min-height: 58px !important;
}
.ves-wrap.fi-shell .ves-breadcrumb strong {
  color: var(--fi-ink) !important;
  font-size: 11px !important;
  letter-spacing: .18em !important;
}
.ves-wrap.fi-shell .ves-global-search {
  background: var(--fi-surface) !important;
  border: 1px solid var(--fi-border) !important;
  box-shadow: none !important;
  border-radius: 12px !important;
}

.ves-wrap.fi-shell .fi-command-canvas,
.ves-wrap.fi-shell .ves-page-body.fi-command-canvas {
  background: var(--fi-bg) !important;
}
.ves-wrap.fi-shell .ves-page-inner {
  max-width: 1260px !important;
  padding: 36px 40px 56px !important;
  margin: 0 auto !important;
}
.ves-wrap.fi-shell .ves-page-head {
  align-items: end !important;
  gap: 24px !important;
  margin-bottom: 24px !important;
}
.ves-wrap.fi-shell .ves-page-title {
  color: var(--fi-ink) !important;
  font-size: clamp(36px, 4vw, 44px) !important;
  line-height: .98 !important;
  letter-spacing: -.055em !important;
  font-weight: 820 !important;
}
.ves-wrap.fi-shell .ves-page-title::before,
.ves-wrap.fi-shell [data-eyebrow]::before {
  color: rgba(17,17,17,.48) !important;
  font-size: 10px !important;
  letter-spacing: .18em !important;
}
.ves-wrap.fi-shell .ves-page-sub,
.ves-wrap.fi-shell .fi-intake-sub {
  color: var(--fi-muted) !important;
  font-size: 15px !important;
  line-height: 1.55 !important;
  max-width: 760px;
}

.ves-wrap.fi-shell .ves-card,
.ves-wrap.fi-shell .ves-command-center-card,
.ves-wrap.fi-shell .fi-evidence-drawer,
.ves-wrap.fi-shell .ves-results,
.fiis-membership-screen .fiis-membership-card,
.fiis-membership-screen .fiis-settings-card {
  background: var(--fi-surface) !important;
  border: 1px solid var(--fi-border) !important;
  border-radius: var(--fi-radius-lg) !important;
  box-shadow: none !important;
}
.ves-wrap.fi-shell .ves-command-center-card {
  padding: 26px !important;
  overflow: visible !important;
}
.ves-wrap.fi-shell .ves-platform-tabs {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  gap: 10px !important;
  padding: 0 0 22px !important;
  border-bottom: 1px solid var(--fi-border) !important;
}
.ves-wrap.fi-shell .ves-tab {
  background: rgba(17,17,17,.045) !important;
  border: 1px solid rgba(17,17,17,.08) !important;
  border-radius: 16px !important;
  min-height: 58px !important;
  box-shadow: none !important;
}
.ves-wrap.fi-shell .ves-tab.active {
  background: var(--fi-ink) !important;
  color: var(--fi-surface) !important;
  border-color: var(--fi-ink) !important;
}

.ves-wrap.fi-shell .fi-command-intro {
  display: grid;
  grid-template-columns: minmax(140px, 220px) 1fr;
  gap: 6px 18px;
  align-items: baseline;
  padding: 0 0 22px;
  margin: 0 0 22px;
  border-bottom: 1px solid var(--fi-border);
}
.ves-wrap.fi-shell .fi-command-intro span {
  color: rgba(17,17,17,.54);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .18em;
  font-weight: 780;
}
.ves-wrap.fi-shell .fi-command-intro strong {
  color: var(--fi-ink);
  font-size: 18px;
  line-height: 1.25;
  letter-spacing: -.025em;
}
.ves-wrap.fi-shell .fi-command-intro em {
  grid-column: 2;
  color: var(--fi-muted);
  font-style: normal;
  line-height: 1.45;
}

.ves-wrap.fi-shell .fi-signal-scan-form .ves-row,
.ves-wrap.fi-shell .fi-signal-scan-form .ves-primary-controls-row {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
  gap: 18px !important;
  margin-top: 18px !important;
}
.ves-wrap.fi-shell .fi-signal-scan-form .ves-label {
  color: rgba(17,17,17,.58) !important;
  font-size: 10px !important;
  letter-spacing: .12em !important;
  text-transform: uppercase !important;
  font-weight: 780 !important;
}
.ves-wrap.fi-shell .fi-signal-scan-form .ves-input,
.ves-wrap.fi-shell .fi-signal-scan-form .ves-select,
.ves-wrap.fi-shell .fi-signal-scan-form .ves-textarea {
  background: rgba(255,250,241,.75) !important;
  border: 1px solid rgba(17,17,17,.16) !important;
  border-radius: 13px !important;
  color: var(--fi-ink) !important;
  box-shadow: none !important;
  font-size: 14px !important;
  line-height: 1.45 !important;
}
.ves-wrap.fi-shell .fi-signal-scan-form .ves-ai-refine-button,
.ves-wrap.fi-shell .ves-mini-btn {
  background: transparent !important;
  color: var(--fi-blue) !important;
  border: 1px solid rgba(36,88,211,.22) !important;
  border-radius: 999px !important;
  font-weight: 720 !important;
  box-shadow: none !important;
}

.ves-wrap.fi-shell .ves-btn-primary,
.ves-wrap.fi-shell .ves-start,
.ves-wrap.fi-shell .fi-action-rail .ves-btn-primary {
  background: var(--fi-blue) !important;
  color: #fff !important;
  border: 1px solid var(--fi-blue) !important;
  border-radius: 999px !important;
  box-shadow: none !important;
  font-size: 13px !important;
  font-weight: 780 !important;
}
.ves-wrap.fi-shell .ves-btn-secondary {
  background: transparent !important;
  color: var(--fi-ink) !important;
  border: 1px solid var(--fi-border) !important;
  border-radius: 999px !important;
  box-shadow: none !important;
}
.ves-wrap.fi-shell button:focus-visible,
.ves-wrap.fi-shell a:focus-visible,
.fiis-membership-screen button:focus-visible,
.fiis-membership-screen a:focus-visible {
  outline: 3px solid rgba(36,88,211,.32) !important;
  outline-offset: 2px !important;
}

.ves-wrap.fi-shell .ves-status.show {
  border-radius: var(--fi-radius-md) !important;
  border: 1px solid rgba(36,88,211,.24) !important;
  background: var(--fi-blue-soft) !important;
  color: var(--fi-ink) !important;
  box-shadow: none !important;
  line-height: 1.45;
}
.ves-wrap.fi-shell .ves-status.show[aria-busy="true"] {
  position: relative;
  overflow: hidden;
}
.ves-wrap.fi-shell .ves-status.show[aria-busy="true"]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--fi-blue), transparent);
  animation: fiis-rc2-runline 1.6s linear infinite;
}
@keyframes fiis-rc2-runline { from { transform: translateX(-60%); } to { transform: translateX(60%); } }
.ves-wrap.fi-shell .fiis-run-explain { margin-top: 8px; color: var(--fi-muted); font-size: 13px; line-height: 1.45; }
.ves-wrap.fi-shell .fiis-run-actions { margin-top: 12px; }

.ves-wrap.fi-shell .ves-results.show,
.ves-wrap.fi-shell .fi-evidence-drawer.show {
  margin-top: 24px !important;
  padding: 24px !important;
  background: var(--fi-surface) !important;
}
.ves-wrap.fi-shell .ves-results-header,
.ves-wrap.fi-shell .ves-results-head {
  border-bottom: 1px solid var(--fi-border) !important;
  padding-bottom: 16px !important;
  margin-bottom: 22px !important;
}
.ves-wrap.fi-shell .ves-results-grid,
.ves-wrap.fi-shell .ves-grid-results,
.ves-wrap.fi-shell .ves-card-grid,
.ves-wrap.fi-shell .ves-result-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)) !important;
  gap: 18px !important;
}
.ves-wrap.fi-shell .ves-result-card,
.ves-wrap.fi-shell .ves-social-card,
.ves-wrap.fi-shell .ves-item-card {
  background: #fffdf8 !important;
  border: 1px solid rgba(17,17,17,.10) !important;
  border-radius: 18px !important;
  box-shadow: none !important;
  overflow: hidden !important;
}
.ves-wrap.fi-shell .ves-result-card img,
.ves-wrap.fi-shell .ves-thumb img,
.ves-wrap.fi-shell .ves-card-thumb img {
  aspect-ratio: 4 / 3;
  object-fit: cover;
  width: 100%;
}
.ves-wrap.fi-shell .ves-result-card .ves-title,
.ves-wrap.fi-shell .ves-result-card .ves-title2,
.ves-wrap.fi-shell .ves-result-card .ves-caption,
.ves-wrap.fi-shell .ves-result-card .ves-body,
.ves-wrap.fi-shell .ves-result-card p,
.ves-wrap.fi-shell .ves-result-card div,
.ves-wrap.fi-shell .fiis-route-label,
.ves-wrap.fi-shell .fiis-route-state {
  overflow-wrap: normal !important;
  word-break: normal !important;
  white-space: normal !important;
  line-height: 1.45 !important;
}
.ves-wrap.fi-shell .ves-result-card a,
.ves-wrap.fi-shell .ves-result-card code,
.ves-wrap.fi-shell .ves-token,
.ves-wrap.fi-shell .fiis-token,
.ves-wrap.fi-shell .ves-url {
  overflow-wrap: anywhere !important;
  word-break: normal !important;
}
.ves-wrap.fi-shell .ves-result-card .ves-caption,
.ves-wrap.fi-shell .ves-result-card .ves-body {
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.ves-wrap.fi-shell .ves-result-actions .ves-btn,
.ves-wrap.fi-shell .ves-card-actions .ves-btn,
.ves-wrap.fi-shell .ves-result-card .ves-mini-btn {
  background: transparent !important;
  color: var(--fi-blue) !important;
  border-color: rgba(36,88,211,.25) !important;
  box-shadow: none !important;
}
.ves-wrap.fi-shell .ves-result-actions .ves-btn:first-child,
.ves-wrap.fi-shell .ves-card-actions .ves-btn:first-child {
  background: var(--fi-blue) !important;
  color: #fff !important;
  border-color: var(--fi-blue) !important;
}
.ves-wrap.fi-shell .fi-signal-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 10px 0;
}
.ves-wrap.fi-shell .fi-signal-card-tags span {
  border: 1px solid rgba(17,17,17,.12);
  border-radius: 999px;
  color: var(--fi-muted);
  font-size: 11px;
  padding: 4px 8px;
}

.ves-wrap.fi-shell .fiis-route-bar,
.ves-wrap.fi-shell .fiis-evidence-gate,
.ves-wrap.fi-shell .fiis-actions,
.ves-wrap.fi-shell .fiis-usage-panel,
.ves-wrap.fi-shell .fiis-recommendations,
.ves-wrap.fi-shell .fiis-ab-test,
.ves-wrap.fi-shell .fiis-detail-section {
  background: transparent !important;
  border: 0 !important;
  border-top: 1px solid var(--fi-border) !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  padding: 22px 0 !important;
}
.ves-wrap.fi-shell .fiis-route-track {
  gap: 10px !important;
}
.ves-wrap.fi-shell .fiis-route-step {
  background: rgba(17,17,17,.045) !important;
  border: 0 !important;
  border-radius: 12px !important;
}
.ves-wrap.fi-shell .fiis-route-state,
.ves-wrap.fi-shell .fiis-chip,
.ves-wrap.fi-shell .fi-status-badge {
  border-radius: 999px !important;
  font-size: 11px !important;
  line-height: 1.2 !important;
}

.ves-wrap.fi-shell .fiis-decision-report,
.ves-wrap.fi-shell .fiis-report-shell,
.ves-wrap.fi-shell .ves-report-preview,
.ves-wrap.fi-shell .ves-report-card,
.ves-wrap.fi-shell [data-report-preview] {
  background: #fffdf8 !important;
  border: 1px solid rgba(17,17,17,.10) !important;
  border-radius: 24px !important;
  box-shadow: var(--fi-shadow-soft) !important;
  color: var(--fi-ink) !important;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
}
.ves-wrap.fi-shell .fiis-decision-report pre,
.ves-wrap.fi-shell .fiis-report-shell pre,
.ves-wrap.fi-shell .ves-report-preview pre {
  background: rgba(17,17,17,.045) !important;
  color: var(--fi-ink) !important;
  border-radius: 14px !important;
  white-space: pre-wrap !important;
  overflow-wrap: anywhere !important;
}

.fiis-membership-screen {
  background: var(--fi-bg) !important;
  color: var(--fi-ink) !important;
}
.fiis-membership-screen .fiis-membership-layout {
  max-width: 1180px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 24px;
}
.fiis-membership-screen .fiis-membership-strip,
.fiis-membership-screen .fiis-plan-options,
.fiis-membership-screen .fiis-pack-grid,
.fiis-membership-screen .fiis-ledger-list {
  border-color: var(--fi-border) !important;
  box-shadow: none !important;
}
.fiis-membership-screen input,
.fiis-membership-screen select {
  border-radius: 12px !important;
  border-color: rgba(17,17,17,.16) !important;
  box-shadow: none !important;
}
.fiis-membership-screen .button-primary {
  background: var(--fi-blue) !important;
  border-color: var(--fi-blue) !important;
  border-radius: 999px !important;
  font-weight: 750;
}

@media (max-width: 960px) {
  .ves-wrap.fi-shell.ves-light-suite { grid-template-columns: 1fr !important; }
  .ves-wrap.fi-shell .fi-sidebar { width: min(88vw, 320px) !important; }
  .ves-wrap.fi-shell .ves-page-inner { padding: 24px 16px 44px !important; }
  .ves-wrap.fi-shell .ves-page-head { align-items: start !important; flex-direction: column; }
  .ves-wrap.fi-shell .fi-signal-scan-form .ves-row,
  .ves-wrap.fi-shell .fi-signal-scan-form .ves-primary-controls-row,
  .ves-wrap.fi-shell .fi-command-intro,
  .fiis-membership-screen .fiis-membership-layout { grid-template-columns: 1fr !important; }
  .ves-wrap.fi-shell .fi-command-intro em { grid-column: 1; }
  .ves-wrap.fi-shell .ves-results-grid,
  .ves-wrap.fi-shell .ves-grid-results,
  .ves-wrap.fi-shell .ves-card-grid,
  .ves-wrap.fi-shell .ves-result-grid { grid-template-columns: 1fr !important; }
}
