/* Margonaut Stage 10.8.21 — focused workspace UI.
 * PRESENTATION ONLY. Loaded last. No new network requests, events, forms or state.
 * All data-ui-view, IDs, billing semantics, auth and legal controls are unchanged.
 */
:root {
  --ui-paper: #f7f8f6;
  --ui-white: #ffffff;
  --ui-ink: #17272f;
  --ui-secondary: #334b55;
  --ui-muted: #667983;
  --ui-line: #e2e8e4;
  --ui-soft: #f5f8f6;
  --ui-forest: #075d4c;
  --ui-forest-hover: #084e42;
  --ui-rail: #14232b;
  --ui-radius: 16px;
  --ui-shadow: 0 1px 2px rgba(25,48,52,.025);
  --fn-paper:var(--ui-paper); --fn-white:var(--ui-white);
  --fn-ink:var(--ui-ink); --fn-marine:var(--ui-forest);
  --fn-muted:var(--ui-muted); --fn-rule:var(--ui-line);
  --fm-line:var(--ui-line); --fm-paper:#fff;
  --mg-border:var(--ui-line); --mg-surface-soft:var(--ui-soft);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  color:var(--ui-ink);
}
html { font-size: 14px; scrollbar-gutter: auto; }
body { background:var(--ui-paper); color:var(--ui-ink); font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif; line-height:1.5; }
.app-layout { background:var(--ui-paper); }
.app-content { background:var(--ui-paper); }
.app-layout > .app-sidebar {
  background:linear-gradient(168deg,#12232b 0%,#172933 70%,#13242d 100%);
  color:#e8f2ed; border-right:1px solid #253f46;
  padding-top:22px;
}
.app-sidebar .sidebar-brand {padding-bottom:20px;margin-bottom:15px;border-bottom:1px solid rgba(223,236,229,.12)}
.app-sidebar .sidebar-brand strong {font-size:19px;font-weight:760;letter-spacing:-.04em}
.app-sidebar .sidebar-brand span {color:#a8bdc1;font-size:10px;letter-spacing:.11em}
.app-sidebar .nav-item {
  min-height:46px;padding:8px 12px;margin:3px 0;gap:11px;
  border-radius:9px;border-left:3px solid transparent;
  color:#d2dfe1;font-size:13px;font-weight:570;
  transition:background-color .16s ease,color .16s ease;
}
.app-sidebar .nav-item:hover {background:#253e46;color:white}
.app-sidebar .nav-item.active,.app-sidebar .nav-item[aria-current="page"] {
  background:linear-gradient(100deg,#29474a,#263e46);color:#fff;
  border-left-color:#ec8b5b;
}
.app-sidebar .nav-item .nav-icon {width:31px;min-width:31px;max-width:31px;height:31px;min-height:31px;max-height:31px;flex-basis:31px;border-color:#3a5860;border-radius:7px;background:rgba(255,255,255,.025)}
.app-sidebar .nav-item.active .nav-icon {background:#39555a;color:#ffad80;border-color:#567078}
.app-sidebar .nav-svg {stroke-width:1.8}
.app-sidebar .sidebar-account {margin-top:auto;border-top:1px solid rgba(223,236,229,.14);padding:17px 8px 6px}
.app-sidebar .sidebar-account-copy {font-size:12px;color:#c9d9da}
.app-sidebar .sidebar-account .button-ghost {width:100%;border:1px solid #58717a;border-radius:9px;background:transparent;color:#fff;font-size:13px;font-weight:680;min-height:42px;margin-top:10px}
.app-sidebar .sidebar-account .button-ghost:hover {background:#273f47}
.workspace-header {padding:22px clamp(22px,3vw,46px) 15px;min-height:105px;border-bottom:1px solid #e4e9e5;background:rgba(248,248,245,.96);box-shadow:none;backdrop-filter:blur(16px)}
.workspace-kicker {font-size:10px;color:#476b71;letter-spacing:.18em;font-weight:800}
.workspace-header h1 {margin:5px 0 3px;font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;font-size:clamp(29px,2.5vw,38px);line-height:1.13;letter-spacing:-.048em;font-weight:780;color:#13252e}
.workspace-header .muted {font-size:13px;line-height:1.45;color:#6a7c82}
.shell {width:calc(100% - clamp(36px,6vw,94px));max-width:1500px;margin:22px auto 64px}
/* Global card grammar */
.card,.shell section.card[data-ui-view],.shell .team-workspace .team-panel,.shell .analytics-page .analytics-report-card,.shell .telegram-page :is(.telegram-hero-card,.telegram-reports-card,.telegram-settings-card),.shell .history-panel {
  background:var(--ui-white);border:1px solid var(--ui-line);border-radius:var(--ui-radius);
  box-shadow:var(--ui-shadow);
}
.shell .card {padding:clamp(20px,2vw,28px)}
.shell .eyebrow,.shell .report-kicker,.shell .telegram-overline {font-size:10px;letter-spacing:.16em;color:#35666d;font-weight:800;line-height:1.35}
.shell .section-heading {margin-bottom:17px;align-items:flex-start;gap:18px}
.shell .section-heading h2,.shell .section-heading h3,.shell .team-panel-heading h3,.shell .telegram-card-heading h3,.shell .analytics-report-card h2 {
  font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;
  color:#1a2b35;font-weight:745;letter-spacing:-.034em;
}
.shell .section-heading h2 {font-size:clamp(19px,1.58vw,23px);line-height:1.3;margin:4px 0 6px}
.shell .section-heading h3 {font-size:18px;line-height:1.3}
.shell :is(.section-copy,.footnote,.team-inline-note) {font-size:12px;line-height:1.55;color:#708089}
.shell .section-heading p.muted {margin-top:4px;max-width:790px}
.shell .view-intro {border-bottom:0;padding:0;margin:0 0 15px}
.shell .view-intro h2 {font-family:inherit;font-weight:760;font-size:23px;letter-spacing:-.035em}
.shell .view-intro .muted {line-height:1.55}
/* Controls — keep original native elements and semantics */
.button,.icon-button,.shell :is(.button,.icon-button) {
  display:inline-flex;align-items:center;justify-content:center;gap:8px;
  min-height:40px;padding:10px 16px;border-radius:9px;
  background:var(--ui-rail);color:white;border:1px solid transparent;
  box-shadow:none;font-family:inherit;font-size:12px;font-weight:720;line-height:1.25;
  text-align:center;transition:background-color .15s ease,border-color .15s ease;
}
.button:hover,.icon-button:hover,.shell :is(.button,.icon-button):hover {background:#21444a;color:#fff;box-shadow:none;transform:none}
.button.button-light,.shell .button.button-light {background:#f5f7f5;color:#23404b;border:1px solid #d4ded9}
.button.button-light:hover,.shell .button.button-light:hover {background:#e9f1ed;color:#174d44}
.button:disabled,.shell .button:disabled {cursor:not-allowed;opacity:.58}
.shell :is(input:not([type="checkbox"]):not([type="radio"]),select,textarea),
.auth-card :is(input:not([type="checkbox"]):not([type="radio"]),select,textarea) {
  min-height:41px;border:1px solid #cedbd7;border-radius:9px;background:#fff;color:var(--ui-ink);
  padding:9px 12px;font:inherit;font-size:13px;line-height:1.35;box-shadow:none;
}
.shell :is(input,select,textarea):focus-visible,.auth-card :is(input,select,textarea):focus-visible {outline:2px solid #459c86;outline-offset:2px}
.shell :is(input,select,textarea):disabled {background:#f3f5f4;color:#7f9091}
.shell label > span:first-child,.shell label > strong:first-child {font-size:12px;font-weight:650;color:#50666e}
.shell :is(input[type="checkbox"],input[type="radio"]) {accent-color:#0b775c;min-width:16px;min-height:16px}
.shell :is(.badge,.status-pill) {border:1px solid #d9e6df;background:#edf4f0;border-radius:7px;color:#346358;padding:6px 10px;font-size:11px;font-weight:730;line-height:1.25;white-space:normal}
.shell :is(.empty,.empty-state,.analytics-empty-state) {
  background:#f8faf8;border:1px dashed #cbdcd5;border-radius:12px;
  padding:clamp(24px,3vw,43px);color:#6b7d84;text-align:center;line-height:1.55;
}
.shell .empty-state strong,.shell .analytics-empty-state strong {font-size:14px;color:#273c42}
.shell :is(table,.table-wrap) {border-radius:10px}
.shell table {border-collapse:separate;border-spacing:0;width:100%;font-size:12px;}
.shell th {background:#f1f5f2;font-size:10px;font-weight:800;letter-spacing:.05em;color:#526972;text-transform:uppercase;}
.shell td,.shell th {padding:12px 13px;vertical-align:middle;border-bottom:1px solid #e8eeea;}
.shell tbody tr:last-child td {border-bottom:0}
.shell tbody tr:hover {background:#fafcfb}
.shell :is(.table-wrap,.team-table-wrap) {max-width:100%;overflow-x:auto}
.shell :is(.financial-auth-context,.section-copy) {overflow-wrap:break-word}
/* Overview — separate generous KPI cards, hierarchy and readable status */
.shell .overview-kpi-strip {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:13px;background:transparent;border:0;border-radius:0;overflow:visible;margin:0 0 18px}
.shell .overview-kpi-card {min-height:143px;border:1px solid var(--ui-line);border-radius:14px;padding:18px 19px;background:white;box-shadow:var(--ui-shadow);gap:10px;transition:border-color .15s ease}
.shell .overview-kpi-card:first-child {background:linear-gradient(135deg,#163842,#0e3337);color:#fff;border-color:#284e52}
.shell .overview-kpi-card:hover {border-color:#a9c8bc;background:#f9fcfb}
.shell .overview-kpi-card:first-child:hover {background:linear-gradient(135deg,#1e4b51,#12343a)}
.shell .overview-kpi-card span {font-size:11px;letter-spacing:.015em;text-transform:none;font-weight:700;color:#63777e}
.shell .overview-kpi-card strong,.shell .overview-kpi-card:first-child strong {font-family:inherit;font-size:clamp(26px,2.3vw,34px);font-weight:770;letter-spacing:-.05em;line-height:1.15}
.shell .overview-kpi-card small {font-size:11px;color:#75868c;margin-top:auto}
.shell .overview-kpi-card:first-child :is(span,small) {color:#c9dddd}
.shell .onboarding-card,.shell .decision-history-card {margin-bottom:17px}
.shell .onboarding-heading h2 {font-family:inherit;font-size:21px;font-weight:760;letter-spacing:-.03em}
.shell .onboarding-heading .muted {font-size:12px;line-height:1.5}
.shell .onboarding-progress {height:4px;border-radius:99px;background:#e4ebe8}
.shell .onboarding-progress > span {background:#e88358;border-radius:99px}
.shell .onboarding-steps {gap:9px}
.shell .onboarding-steps > * {border-radius:10px !important;border-color:#e2e9e6 !important;}
.shell .onboarding-current {border:1px solid #dfe9e4;border-radius:11px;background:#f4f8f5;padding:16px 18px}
.shell .onboarding-current strong {font-size:18px;font-weight:750}
.shell .profit-radar {margin-bottom:17px}
.shell .radar-summary {gap:10px;background:transparent;border:0}
.shell .radar-summary > div {background:#f5f8f6;border:1px solid #e0e8e2;border-radius:11px;padding:16px}
.shell .radar-summary strong {font-family:inherit;font-size:clamp(23px,2vw,29px);font-weight:750;letter-spacing:-.04em}
.shell .radar-subtitle {font-size:15px;font-family:inherit;font-weight:750}
.shell .dashboard-command-center {margin-bottom:17px}
.shell .dashboard-health-grid {gap:10px;background:transparent;border:0;border-radius:0;overflow:visible}
.shell .dashboard-health-grid > div {background:#f6f9f7;border:1px solid #e1eae5;border-radius:10px;padding:15px}
.shell .dashboard-health-grid span {font-size:10px;letter-spacing:0;text-transform:none}
.shell .dashboard-action {border-radius:10px;padding:14px 16px}
.shell .decision-history-list > * {border-radius:10px}
/* Analytics — dense but calm; charts must continue rendering real SVGs */
.shell .analytics-page .analytics-report-card {padding:23px;margin-bottom:16px}
.shell :is(.analytics-kpis,.analytics-summary-grid,.analytics-metric-grid) > * {border-radius:11px;min-width:0}
.shell .analytics-chart-wrap,.shell .organization-analytics-chart {background:#fff;border-color:#e2e9e5;border-radius:10px;min-height:0}
.shell .analytics-chart-detail {border-left:3px solid #167e68;border-radius:4px;background:#f2f8f4}
.shell .analytics-chart-interactive:focus-visible {outline:2px solid #147e64;outline-offset:2px}
.shell .analytics-value-label {font-family:inherit}
/* Products, monitoring, comparison: compact functional panels */
.shell :is(.products-page,.products-workspace,.product-catalog,.competitors-workspace,.competitors-page) {min-width:0}
.shell :is(.stores-panel,.products-panel,.wb-import-panel,.competitor-workspace-card,.competitors-card,.competitor-add-panel) {border-radius:13px}
.shell :is(.products-store-layout,.products-grid,.competitor-filters,.competitor-add-grid) {gap:14px}
.shell :is(.wb-import-actions,.analytics-controls,.dashboard-command-actions,.telegram-primary-actions) {gap:9px;flex-wrap:wrap}
.shell .wb-catalog-panel {border-radius:12px;background:#fff}
.shell #opportunity-radar .opportunity-metrics > div {border-radius:10px;min-height:112px;background:#f3f8f6}
.shell #opportunity-radar .opportunity-insight,.shell #opportunity-radar .opportunity-pair-analysis {border-radius:11px;background:#f9fbfa}
.shell #opportunity-radar .opportunity-history-row {border-bottom-color:#e4eae7}
.shell :is(.history-panel,.history-row,.event-card,.price-chart-wrap) {border-radius:11px}
/* Alerts and decisions */
.shell :is(.event-filters,.decision-filters,.events-filters) {border-radius:10px;background:#f4f8f5}
.shell .event-card {background:#fff;border-radius:11px;padding:14px}
.shell .event-card p {font-size:12px;line-height:1.5}
/* Subscription: preserve every check, policy link, warning and action. */
.shell #subscription-card {padding:clamp(20px,2vw,28px)}
.shell #subscription-card > .section-heading {margin-bottom:15px}
.shell .subscription-stats {gap:9px}
.shell .subscription-stats > div {border-radius:10px;background:#f5f8f6;border:1px solid #e1eae5;padding:13px}
.shell .subscription-stats > div span {font-size:11px;color:#718189}
.shell .subscription-stats > div strong {font-size:14px;font-weight:730}
.shell .billing-clarity {background:#f5faf7;border:1px solid #dbe8df;border-radius:13px;margin-top:16px;padding:18px}
.shell .billing-clarity-heading {margin-bottom:12px}
.shell .billing-clarity-heading h3 {font-family:inherit;font-size:19px;font-weight:740}
.shell .billing-terms-grid {gap:9px}
.shell .billing-terms-grid > div {border-radius:10px;padding:12px 13px}
.shell .billing-terms-grid strong {font-size:13px}
.shell .billing-disclosure {font-size:12px;line-height:1.55}
.shell .billing-review-panel,.shell .billing-cancel-panel {border-radius:13px;padding:18px}
.shell .billing-review-heading h3 {font-family:inherit;font-size:19px;font-weight:740}
.shell .billing-review-lead {font-size:12px;line-height:1.55;margin:9px 0}
.shell .billing-review-panel .subscription-legal-check {border-radius:9px;margin-bottom:8px;padding:12px 13px;line-height:1.5;font-size:12px;min-height:0}
.shell .billing-review-panel .subscription-legal-check input {accent-color:#08644f}
.shell .billing-consent-timeline {margin-top:14px;border-radius:12px;padding:0;border:1px solid #e0e8e4;background:white;overflow:hidden}
.shell .billing-consent-timeline > summary {padding:16px 18px;display:flex;align-items:center;justify-content:space-between;gap:12px;cursor:pointer;list-style:none;color:#223941}
.shell .billing-consent-timeline > summary::-webkit-details-marker {display:none}
.shell .billing-consent-timeline > summary::after {content:"⌄";font-size:19px;color:#50746b;line-height:1}
.shell .billing-consent-timeline[open] > summary::after {transform:rotate(180deg)}
.shell .billing-consent-timeline > summary strong {font-size:15px;font-weight:760}
.shell .billing-consent-timeline > summary span {color:#75858a;font-size:11px;margin-left:auto}
.shell .billing-consent-content {padding:0 17px 16px}
.shell .billing-consent-history {gap:6px}
.shell .billing-consent-entry {border-radius:9px}
.shell .subscription-plans {margin-top:21px;padding-top:19px}
.shell .plan-grid {gap:12px}
.shell .plan-card {border-radius:12px;padding:17px;gap:11px;min-height:215px}
.shell .plan-card.current {border-color:#159373;box-shadow:0 0 0 1px #159373;background:#f6fdfa}
.shell .plan-card > div > span {color:#0b684f}
.shell .plan-card .button {margin-top:auto}
.shell .plan-card p {font-size:12px}
.shell .usage-grid > div {border-radius:10px}
/* Team and settings use same cards, forms and two-column rhythms */
.shell .team-workspace .team-hero-panel {border-radius:13px;background:linear-gradient(120deg,#143640,#0e2b33);padding:20px 24px}
.shell .team-summary-grid {gap:10px}
.shell .team-summary-card {border-radius:11px;padding:17px;background:#f7faf8}
.shell .team-summary-card strong {font-family:inherit;font-weight:750;font-size:clamp(20px,2vw,27px)}
.shell .team-workspace .team-panel {padding:20px 23px;margin-bottom:16px}
.shell .team-panel-heading {margin-bottom:16px}
.shell .team-panel-heading h3 {font-size:19px}
.shell .team-panel-heading p {color:#74848a;font-size:12px;line-height:1.5}
.shell .team-invite-form {gap:12px;align-items:end}
.shell .team-lower-grid {gap:15px}
.shell .account-settings-card,.shell .settings-card {margin-bottom:17px}
.shell .account-settings-grid {gap:11px}
.shell .account-setting-panel {border-radius:11px;background:#f8faf8;padding:17px}
.shell .privacy-points {gap:10px}
.shell .privacy-points > div {background:#f5f8f6;border:1px solid #e0e9e4;border-radius:11px;padding:16px}
.shell .privacy-points > div:last-child {background:#fff6f3;border-color:#efdcd7}
.shell .danger-zone {border-radius:10px}
/* Telegram settings */
.shell .telegram-settings-grid {gap:14px}
.shell .telegram-toggle,.shell .telegram-report-option,.shell .telegram-digest-switch {border-radius:10px}
.shell .telegram-card-heading h3 {font-size:19px}
/* Balanced mobile rendering; no horizontal page overflow */
@media (max-width:1250px) {
  .shell .overview-kpi-strip {grid-template-columns:repeat(2,minmax(0,1fr))}
  .shell .dashboard-health-grid {grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width:900px) {
  .workspace-header {min-height:79px;padding:16px 20px}
  .workspace-header h1 {font-size:28px}
  .shell {width:calc(100% - 34px);margin:17px auto 42px}
  .app-layout > .app-sidebar {width:min(300px,86vw)}
  .shell .card {padding:18px}
  .financial-mobile-nav-toggle {border-radius:9px;border-color:#d0dad6;background:white}
}
@media (max-width:650px) {
  .shell {width:calc(100% - 24px);margin-top:13px}
  .workspace-header {padding:13px 14px}
  .workspace-header h1 {font-size:25px}
  .shell .overview-kpi-strip {gap:9px}
  .shell .overview-kpi-card {padding:13px;min-height:116px}
  .shell .overview-kpi-card strong {font-size:clamp(21px,6vw,30px)}
  .shell .overview-kpi-card small {font-size:10px}
  .shell .section-heading {gap:10px;flex-wrap:wrap}
  .shell .section-heading h2 {font-size:19px}
  .shell .dashboard-health-grid {grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
  .shell .dashboard-health-grid > div {padding:12px}
  .shell .billing-terms-grid,.shell .plan-grid,.shell .account-settings-grid,.shell .privacy-points,.shell .team-summary-grid {grid-template-columns:minmax(0,1fr)}
  .shell .billing-consent-timeline > summary span {display:none}
  .shell .team-workspace .team-panel {padding:16px}
  .shell .table-wrap {overflow-x:auto}
  .shell .card {padding:16px}
  .shell .button,.shell select {max-width:100%}
}
@media (prefers-reduced-motion:reduce) {
  .app-sidebar .nav-item,.button,.icon-button {transition:none}
}

/* Stage 10.8.21 / Clarity system
   Reduce repeated microcopy and card-inside-card treatment; keep all status, legal,
   authentication and billing controls and all JS selectors unchanged. */
:root { --ui-radius: 12px; }
body { font-size:14px; line-height:1.5; }
/* 01 — A single page title is enough. The current view remains named for assistive technology. */
.workspace-header { min-height:76px; padding:17px clamp(21px,3.1vw,43px); background:#fff; border-color:var(--ui-line); backdrop-filter:none; }
.workspace-header .workspace-kicker,.workspace-header #view-description { display:none; }
.workspace-header h1 { font-size:clamp(25px,2vw,31px);line-height:1.15;letter-spacing:-.044em;margin:0;font-weight:750; }
.shell { margin:20px auto 54px; }
.shell .view-intro { display:none; }
/* Section overlines repeat the menu and card title. They are never legal/financial disclosures. */
.shell .section-heading > div > p.eyebrow { display:none; }
.shell .section-heading { margin-bottom:15px; gap:12px; }
.shell .section-heading h2 { margin:0; font-size:20px; line-height:1.28; font-weight:740; }
.shell .section-heading h3 { margin:0; font-size:17px; }
.shell .section-heading .muted { margin-top:5px; }
.shell .card { padding:21px 23px; border-radius:12px; box-shadow:none; }
.shell .card,.shell .team-workspace .team-panel,.shell .history-panel { box-shadow:none; }
.shell :is(.button,.icon-button) { min-height:40px; font-size:13px; font-weight:650; letter-spacing:0; }
.shell :is(input:not([type="checkbox"]):not([type="radio"]),select,textarea) { font-size:13px; }
.shell :is(.badge,.status-pill) { font-size:11px; font-weight:650; letter-spacing:0; }
.shell :is(.footnote,.section-copy,.team-inline-note) { font-size:12px; line-height:1.48; }
.shell label > span:first-child { font-weight:650; }
.shell table th { text-transform:none;letter-spacing:0;font-size:12px;font-weight:650; }
.shell table td { font-size:13px; }
/* 02 — Overview: functional summaries, not stacked secondary labels. */
.shell .overview-kpi-strip { gap:10px; margin-bottom:14px; }
.shell .overview-kpi-card { min-height:122px; padding:15px 17px; border-radius:12px; gap:7px; }
.shell .overview-kpi-card span {font-size:12px;font-weight:650}
.shell .overview-kpi-card small {font-size:11px;}
.shell :is(.profit-radar,.dashboard-command-center,.decision-history-card) { margin-bottom:14px; }
.shell .radar-summary > div,.shell .dashboard-health-grid > div { padding:13px 15px; background:#f9fbfa; }
.shell .dashboard-health-grid span {font-size:12px;}
.shell .overview-heading .section-copy { display:none; }
/* 03 — Team: drop the redundant banner and mini captions; the role remains in summary. */
.shell .team-workspace { display:grid; gap:13px; }
.shell .team-hero-panel { display:none; }
.shell .team-summary-grid { gap:10px; margin:0; }
.shell .team-summary-card { padding:15px 17px; background:#fff; border:1px solid var(--ui-line); border-radius:11px; }
.shell .team-summary-card > span { font-size:12px; }
.shell .team-summary-card strong { font-size:25px; }
.shell .team-summary-card small { display:none; }
.shell .team-workspace .team-panel { margin:0; padding:21px 23px; border-radius:12px; }
.shell .team-panel-heading { margin-bottom:14px; padding-bottom:0; border-bottom:0; }
.shell .team-panel-heading h3 { font-size:18px; }
.shell .team-panel-heading p {display:none}
.shell .team-members-panel .team-panel-heading p {display:block;font-size:12px;margin-top:5px}
.shell .team-invite-form { background:transparent; padding:0; border:0; border-radius:0; }
.shell .team-invite-form .button { min-height:41px; }
.shell .team-lower-grid { gap:13px; }
/* 04 — Product, market and comparison use a single input surface per action. */
.shell :is(.product-import-card,.competitor-workspace-card,.competitors-card,.opportunity-radar) {margin-bottom:14px;}
.shell :is(.wb-connection-form,.competitor-form,.opportunity-form,.team-invite-form) {background:transparent;border-color:transparent;}
.shell :is(.wb-connection-card,.product-import-card,.competitors-card) > .footnote { margin-top:9px; }
.shell #product-import-card .wb-catalog-heading { margin-bottom:12px; }
.shell :is(.competitor-workspace-summary,.overview-metrics) { gap:8px; }
.shell .competitor-workspace-summary .overview-metric {border-radius:10px;background:#f8faf9;}
.shell #opportunity-radar .opportunity-compare-workspace { background:transparent; }
/* 05 — Settings: three clear tasks, privacy explanation available on demand. */
.shell .wb-connection-card { margin-bottom:13px; }
.shell .wb-connection-card .section-copy { display:none; }
.shell .wb-connection-card .wb-connection-form { background:transparent; padding:0; }
.shell .account-settings-card,.shell .settings-card { margin-bottom:13px; }
.shell .account-settings-grid { gap:11px; }
.shell .account-setting-panel { background:#fff; border:1px solid var(--ui-line);padding:17px; }
.shell #account-settings-card .account-setting-panel > p.muted { display:none; }
.shell #account-settings-card #account-password-form > p.muted { display:block; font-size:12px; }
.shell .privacy-explainer {margin:0 0 13px;border:1px solid var(--ui-line);border-radius:10px;background:#fff;}
.shell .privacy-explainer > summary {padding:13px 16px;cursor:pointer;list-style:none;font-size:13px;font-weight:680;color:#24433d;}
.shell .privacy-explainer > summary::-webkit-details-marker {display:none;}
.shell .privacy-explainer > summary::after {content:'+';float:right;font-size:18px;font-weight:400;line-height:1;}
.shell .privacy-explainer[open] > summary::after {content:'−';}
.shell .privacy-explainer .privacy-points {padding:0 13px 13px;}
.shell .privacy-card .legal-links {padding:5px 0 13px;}
/* 06 — Telegram: labels are the controls; remove secondary commentary inside each toggle. */
.shell .telegram-card-heading p,.shell .telegram-toggle small {display:none;}
.shell .telegram-card-heading { margin-bottom:15px; padding-bottom:11px; }
.shell .telegram-card-heading h3 {font-size:18px;}
.shell .telegram-toggle { min-height:45px; }
.shell .telegram-page {gap:13px;}
/* 07 — Billing is intentionally not simplified by hiding conditions or consent.
          Compact structural furniture while leaving every legal word visible. */
.shell .billing-clarity {margin-top:14px;padding:16px;}
.shell .billing-review-panel,.shell .billing-cancel-panel {padding:16px;}
.shell .billing-terms-grid > div {padding:12px;}
.shell .billing-review-panel .subscription-legal-check {padding:13px 14px;line-height:1.55;}
.shell .billing-disclosure,.shell .billing-review-lead {font-size:12px;line-height:1.6;}
/* 08 — Make touch targets and tables usable on small screens without breaking content. */
@media(max-width:900px) {
 .workspace-header {min-height:66px;padding:13px 19px;}
 .workspace-header h1 {font-size:25px;}
 .shell {margin:14px auto 42px;}
 .shell .card,.shell .team-workspace .team-panel {padding:17px;}
}
@media(max-width:650px) {
 .workspace-header {min-height:62px;padding:12px 14px;}
 .workspace-header h1 {font-size:23px;}
 .shell .card,.shell .team-workspace .team-panel {padding:16px;}
 .shell .team-summary-grid {grid-template-columns:repeat(2,minmax(0,1fr));}
 .shell .team-summary-card {padding:13px;}
 .shell .team-summary-card strong {font-size:21px;}
 .shell .overview-kpi-card {min-height:112px;padding:13px;}
 .shell :is(.wb-connection-form,.team-invite-form,.opportunity-form) {gap:10px;}
 .shell .team-switcher {align-items:stretch;}
 .shell .billing-consent-timeline>summary {gap:6px;}
}
@media(prefers-reduced-motion:reduce) { .shell * {scroll-behavior:auto;} }

/* Independent settings cards, not nested inside the WB connection surface. */
.shell > .wb-connection-card,.shell > .account-settings-card,.shell > .privacy-card {margin-bottom:13px;}
.shell .team-summary-grid {background:transparent;border:0;overflow:visible;}
.shell .workspace .main-panel {min-height:0;}

.shell .subscription-trial-note {color:#5d706f;font-size:12px;line-height:1.5;margin:5px 0 0;}

/* Stage 10.8.22 — meaningful status on the surface, supporting detail on demand. */
.workspace-header-actions .demo-mode-indicator { position:relative; align-self:center; flex-shrink:0; z-index:44; }
.demo-mode-indicator summary { display:inline-flex;align-items:center;gap:7px;list-style:none;cursor:pointer;padding:7px 11px;border:1px solid #d7e3dc;border-radius:99px;background:#edf4f0;color:#34655b;font-size:11px;font-weight:750;white-space:nowrap; }
.demo-mode-indicator summary::-webkit-details-marker {display:none}
.demo-mode-indicator summary::before {content:"";width:6px;height:6px;flex-shrink:0;border-radius:50%;background:#5b9b7d;}
.demo-mode-indicator summary:focus-visible,.analytics-source-details summary:focus-visible,.radar-method-disclosure summary:focus-visible {outline:2px solid #3d987b;outline-offset:3px;}
.demo-mode-indicator[open] summary {background:#e0eee6;border-color:#a8c9b5}
.demo-mode-explanation {position:absolute;right:0;top:calc(100% + 9px);width:min(315px,calc(100vw - 30px));padding:16px 17px;background:#fff;border:1px solid #d9e5df;border-radius:12px;box-shadow:0 12px 28px rgba(27,57,49,.12);color:#334950;font-size:12px;line-height:1.55;overflow-wrap:anywhere;}
.demo-mode-explanation strong {display:block;color:#20353a;font-size:13px;}
.demo-mode-explanation p {margin:6px 0 0;}
.shell .radar-sandbox-note {display:inline-flex;align-items:center;background:transparent;border:0;border-left:0;color:#71817c;padding:0;margin:5px 0 15px;font-size:11px;line-height:1.5;}
.shell .radar-sandbox-note.hidden {display:none!important}
.shell .radar-method-disclosure {border-top:1px solid #e6ede7;margin-top:16px;padding-top:12px;}
.shell .radar-method-disclosure summary,.shell .analytics-source-details summary {display:inline-flex;align-items:center;gap:7px;color:#60737a;font-size:12px;font-weight:650;cursor:pointer;list-style:none;}
.shell .radar-method-disclosure summary::-webkit-details-marker,.shell .analytics-source-details summary::-webkit-details-marker {display:none}
.shell .radar-method-disclosure summary::after,.shell .analytics-source-details summary::after {content:"⌄";font-size:14px;line-height:1;transform:translateY(-2px);}
.shell .radar-method-disclosure[open] summary::after,.shell .analytics-source-details[open] summary::after {transform:rotate(180deg) translateY(1px);}
.shell .radar-method-disclosure .radar-method {margin:11px 0 0;color:#657c79;font-size:12px;line-height:1.65;max-width:820px;}
.shell .analytics-page-toolbar {align-items:flex-start;min-height:0;padding:0 2px 7px;}
.shell .analytics-page-toolbar h2 {font:750 clamp(18px,1.4vw,21px)/1.3 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;letter-spacing:-.025em;margin:0 0 7px;color:#1c3039;}
.shell .analytics-data-status {display:flex;align-items:flex-start;gap:8px;margin:0;color:#516b62;font-size:12px;line-height:1.5;max-width:680px;}
.shell .analytics-data-status::before {content:"";flex-shrink:0;width:7px;height:7px;margin-top:6px;border-radius:50%;background:#3c947a;}
.shell .analytics-data-status.is-limited {color:#8b6340;}
.shell .analytics-data-status.is-limited::before {background:#d29d56;}
.shell .analytics-source-details {margin-top:9px;max-width:700px;}
.shell .analytics-source-details p {font-size:12px;line-height:1.6;margin:9px 0 2px;max-width:660px;color:#647681;}
@media(max-width:900px) { .workspace-header-actions .demo-mode-indicator {order:-1;} }
@media(max-width:620px) {
 .workspace-header-actions .demo-mode-indicator {margin-left:auto;}
 .demo-mode-indicator summary {padding:6px 9px;}
 .shell .analytics-data-status {font-size:12px;}
 .shell .analytics-page-toolbar {gap:14px;}
}

/* Stage 10.8.23: analytics filter only; detailed source notes live below reports. */
.shell .analytics-page-toolbar{justify-content:flex-end;align-items:center;padding:11px 15px;background:#fff;border:1px solid #e2e9e5;border-radius:11px;margin:0 0 15px;min-height:0}
.shell .analytics-page-toolbar .analytics-controls{margin-left:auto;align-items:center}
.shell .analytics-page-toolbar .analytics-controls label{display:flex;align-items:center;gap:10px;min-width:0}
.shell .analytics-page-toolbar .analytics-controls label>span{font-size:12px;letter-spacing:0;font-weight:650;text-transform:none}
.shell .analytics-page-toolbar .analytics-controls select{min-width:132px}
.shell .analytics-method-footer{margin:14px 2px 0;border-top:1px solid #e3ebe7;padding:11px 5px;color:#647580}
.shell .analytics-method-footer>summary{font-size:12px;font-weight:600;cursor:pointer;display:inline-flex;align-items:center;gap:5px}
.shell .analytics-method-footer>summary:focus-visible{outline:2px solid #16846c;outline-offset:3px}
.shell .analytics-method-footer .analytics-data-status{margin-top:12px}
.shell .analytics-method-footer #analytics-source-note{font-size:12px;line-height:1.55;max-width:850px;margin:8px 0}
@media(max-width:620px){.shell .analytics-page-toolbar{padding:10px}.shell .analytics-page-toolbar .analytics-controls{width:100%;justify-content:flex-end}.shell .analytics-page-toolbar .analytics-controls select{min-width:110px}}
/* Stage 10.8.23 finishing pass: period selector is the only visible control. */
.shell .analytics-page-toolbar{padding:0;border:0;background:transparent;border-radius:0;box-shadow:none;margin:0 0 13px;justify-content:flex-end}
.shell .analytics-page-toolbar .analytics-controls{display:flex;align-items:center;justify-content:flex-end;width:auto;margin-left:auto}
.shell .analytics-page-toolbar .analytics-controls label{display:block;position:relative;min-width:0}
.shell .analytics-page-toolbar .analytics-controls label>span{position:absolute;width:1px;height:1px;overflow:hidden;white-space:nowrap;clip-path:inset(50%)}
.shell .analytics-page-toolbar .analytics-controls select{height:40px;min-width:146px}
.shell .analytics-page-toolbar #organization-analytics-refresh{display:none}
@media(max-width:620px){.shell .analytics-page-toolbar{padding:0}.shell .analytics-page-toolbar .analytics-controls{width:auto}.shell .analytics-page-toolbar .analytics-controls select{min-width:130px}}
