:root {
  --bg: #0c1017;
  --surface: #151d2b;
  --surface-2: #1c2638;
  --border: #2a3a52;
  --text: #e8edf4;
  --muted: #8b9cb3;
  --accent: #63b3ff;
  --accent-glow: rgba(99, 179, 255, 0.25);
  --accent-dim: #2d6fd4;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Segoe UI", system-ui, sans-serif;
  background: radial-gradient(ellipse 120% 80% at 50% -20%, #1a2840 0%, var(--bg) 55%);
  color: var(--text);
  line-height: 1.5;
}

.layout {
  max-width: 1140px;
  margin: 0 auto;
  padding: 2rem 1.25rem 3rem;
}

.header-brand {
  display: flex;
  align-items: flex-start;
  gap: 1.25rem 1.5rem;
  flex-wrap: wrap;
}

.header-logo {
  height: 48px;
  width: auto;
  max-width: min(200px, 46vw);
  object-fit: contain;
  flex-shrink: 0;
}

.header-titles {
  flex: 1;
  min-width: min(100%, 220px);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.header-titles h1 {
  margin: 0 0 0.35rem;
  font-size: 1.75rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.subtitle code {
  font-size: 0.85em;
  background: var(--surface);
  padding: 0.12rem 0.4rem;
  border-radius: 4px;
  border: 1px solid var(--border);
}

.kpi {
  margin: 2rem 0;
}

.kpi-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: stretch;
}

.kpi-row .kpi-card {
  flex: 1 1 260px;
  max-width: none;
}

.kpi-card {
  background: linear-gradient(145deg, var(--surface) 0%, var(--surface-2) 100%);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.5rem 1.75rem;
  width: 100%;
  max-width: none;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.kpi-label {
  display: block;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 0.5rem;
}

.kpi-value {
  font-size: 2.35rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
  text-shadow: 0 0 40px var(--accent-glow);
}

.kpi-value-pro {
  color: #c4b5fd;
  text-shadow: 0 0 36px rgba(196, 181, 253, 0.35);
}

.kpi-value-today {
  color: #5eead4;
  text-shadow: 0 0 32px rgba(94, 234, 212, 0.22);
}

.chart-section {
  background: linear-gradient(165deg, var(--surface) 0%, #121a28 100%);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.35rem 1.5rem 1.6rem;
  box-shadow: 0 12px 48px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.chart-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.35rem;
}

.chart-toolbar h2 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 600;
}

.toolbar-right {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem 0.75rem;
}

@media (max-width: 720px) {
  .layout {
    padding: 1.25rem 0.9rem 2.25rem;
  }

  .header-logo {
    height: 42px;
  }

  .header-titles h1 {
    font-size: 1.4rem;
  }

  .kpi {
    margin: 1.25rem 0;
  }

  .kpi-row {
    gap: 0.75rem;
  }

  .kpi-row .kpi-card {
    flex: 1 1 100%;
  }

  .kpi-card {
    padding: 1.1rem 1.15rem;
  }

  .kpi-value {
    font-size: 2.05rem;
  }

  .chart-section {
    padding: 1.05rem 1rem 1.15rem;
  }

  .chart-toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .toolbar-right {
    justify-content: flex-start;
  }

  .period-select {
    min-width: min(100%, 260px);
  }
}

@media (max-width: 420px) {
  .tabs {
    width: 100%;
    justify-content: space-between;
  }

  .tab {
    flex: 1 1 auto;
    padding: 0.45rem 0.6rem;
    text-align: center;
  }

  .chart-actions {
    width: 100%;
  }

  .action-btn {
    flex: 1 1 auto;
    text-align: center;
  }

  .chart-wrap {
    height: min(380px, 56vh);
  }
}

.chart-type-toggle {
  display: flex;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg);
}

.icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 36px;
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
}

.icon-btn:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

.icon-btn.active {
  color: #fff;
  background: var(--accent-dim);
}

.tabs {
  display: flex;
  gap: 0.35rem;
  background: var(--bg);
  padding: 4px;
  border-radius: 10px;
  border: 1px solid var(--border);
}

.tab {
  border: none;
  background: transparent;
  color: var(--muted);
  padding: 0.45rem 0.85rem;
  border-radius: 8px;
  font-size: 0.8125rem;
  cursor: pointer;
  font-family: inherit;
  transition: color 0.15s, background 0.15s;
}

.tab:hover {
  color: var(--text);
}

.tab.active {
  background: var(--accent-dim);
  color: #fff;
}

.chart-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.action-btn {
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text);
  font-size: 0.75rem;
  padding: 0.4rem 0.75rem;
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  transition: border-color 0.15s, background 0.15s;
}

.action-btn:hover:not(:disabled) {
  border-color: var(--accent);
  background: rgba(99, 179, 255, 0.08);
}

.action-btn:disabled,
.action-btn.is-disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.period-filter {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 1rem;
  margin-bottom: 0.65rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--border);
}

.period-filter--compact {
  padding-top: 0.35rem;
}

.period-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.period-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.65rem;
  flex: 1;
  min-width: 0;
}

.period-select {
  min-width: 200px;
  max-width: 100%;
  padding: 0.45rem 0.65rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
  font-size: 0.875rem;
  cursor: pointer;
}

.period-select:focus {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.period-custom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.5rem;
}

.period-date {
  padding: 0.4rem 0.5rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
  font-size: 0.8125rem;
  color-scheme: dark;
}

.period-date:focus {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.period-sep {
  font-size: 0.8rem;
  color: var(--muted);
}

.action-btn.primary {
  background: var(--accent-dim);
  border-color: transparent;
  color: #fff;
}

.action-btn.primary:hover:not(:disabled) {
  background: #3d7fd4;
  border-color: transparent;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hint {
  margin: 0 0 0.85rem;
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.45;
}

.chart-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem;
  margin-bottom: 0.85rem;
}

@media (max-width: 560px) {
  .chart-stats {
    grid-template-columns: 1fr;
  }
}

.stat {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.65rem 0.85rem;
}

.stat-label {
  display: block;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-bottom: 0.2rem;
}

.stat-value {
  font-size: 1.15rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
}

.hover-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 0.75rem;
  padding: 0.65rem 0.9rem;
  margin-bottom: 0.75rem;
  background: rgba(99, 179, 255, 0.06);
  border: 1px solid rgba(99, 179, 255, 0.2);
  border-radius: 10px;
  min-height: 2.75rem;
}

.hover-strip-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  flex-shrink: 0;
}

.hover-strip-detail {
  font-size: 0.875rem;
  color: #c5d2e3;
}

.hover-strip-detail strong {
  color: var(--accent);
  font-weight: 700;
}

.hover-period {
  color: var(--muted);
}

.chart-wrap {
  position: relative;
  height: min(460px, 58vh);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid var(--border);
  padding: 0.5rem 0.35rem 0.35rem;
  box-shadow: inset 0 2px 24px rgba(0, 0, 0, 0.35);
}

.chart-wrap-pro {
  height: min(400px, 52vh);
}

.chart-wrap-maintenance {
  height: min(400px, 52vh);
}

.chart-wrap-pie {
  height: min(360px, 48vh);
}

.chart-block-divider {
  height: 1px;
  margin: 1.75rem 0 1.25rem;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
}

.chart-subhead {
  margin: 0 0 0.35rem;
}

.chart-subtitle {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
}

.chart-subdesc {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.45;
}

.chart-subdesc code {
  font-size: 0.85em;
  background: var(--bg);
  padding: 0.08rem 0.35rem;
  border-radius: 4px;
  border: 1px solid var(--border);
}

.chart-subdesc .maint-sql-hint {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.72rem;
  line-height: 1.4;
  word-break: break-word;
  white-space: pre-wrap;
  color: #a8b8cc;
}

.chart-subdesc .maint-ref-note {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.78rem;
  color: var(--muted);
}

.hover-strip-pro .hover-strip-label {
  color: #c4b5fd;
}

.hover-strip-pro .hover-strip-detail strong {
  color: #c4b5fd;
}

.hover-strip-maintenance .hover-strip-label {
  color: #5eead4;
}

.hover-strip-maintenance .hover-strip-detail strong {
  color: #5eead4;
}

.funnel-section {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.funnel-title {
  margin: 0 0 0.5rem;
  font-size: 1.35rem;
  font-weight: 600;
}

.funnel-intro {
  margin: 0 0 1.25rem;
  font-size: 0.85rem;
  color: var(--muted);
  max-width: 820px;
  line-height: 1.5;
}

.funnel-intro code {
  font-size: 0.8em;
  background: var(--surface);
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  border: 1px solid var(--border);
}

.funnel-overview-card {
  background: linear-gradient(168deg, rgba(21, 29, 43, 0.95) 0%, rgba(18, 26, 40, 0.98) 100%);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.15rem 1.25rem 1.35rem;
  margin-bottom: 1.35rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.funnel-overview-title {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
  font-weight: 600;
}

.funnel-overview-lead {
  margin: 0 0 0.5rem;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.5;
  max-width: 900px;
}

.funnel-overview-lead code {
  font-size: 0.85em;
  background: var(--bg);
  padding: 0.08rem 0.35rem;
  border-radius: 4px;
  border: 1px solid var(--border);
}

.funnel-overview-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  margin-bottom: 0.65rem;
}

.funnel-overview-caption {
  margin: 0 0 0.85rem;
  font-size: 0.78rem;
  color: #a8b8cc;
}

.funnel-overview-root {
  min-height: 2rem;
}

.funnel-overview-loading,
.funnel-overview-error {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
}

.funnel-overview-error {
  color: #f0a0a8;
}

.funnel-overview-stages {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.funnel-stage-row {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 2.2fr) auto;
  gap: 0.65rem 0.85rem;
  align-items: center;
}

@media (max-width: 640px) {
  .funnel-stage-row {
    grid-template-columns: 1fr;
    gap: 0.35rem;
  }

  .funnel-stage-value {
    justify-self: start;
  }
}

.funnel-stage-label {
  font-size: 0.78rem;
  line-height: 1.35;
  color: var(--text);
}

.funnel-stage-bar-wrap {
  height: 30px;
  background: rgba(0, 0, 0, 0.28);
  border-radius: 9px;
  overflow: hidden;
  border: 1px solid rgba(42, 58, 82, 0.85);
}

.funnel-stage-bar {
  height: 100%;
  border-radius: 8px;
  min-width: 3px;
  transition: width 0.45s ease;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.funnel-stage-bar--cad {
  background: linear-gradient(90deg, #94a3b8, #64748b);
}

.funnel-stage-bar--guided {
  background: linear-gradient(90deg, #63b3ff, #3d8bfd);
}

.funnel-stage-bar--tier {
  background: linear-gradient(90deg, #a78bfa, #7c3aed);
}

.funnel-stage-bar--banner {
  background: linear-gradient(90deg, #fbbf24, #d97706);
}

.funnel-stage-bar--pro {
  background: linear-gradient(90deg, #c4b5fd, #8b5cf6);
}

.funnel-stage-value {
  font-size: 0.88rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--text);
  text-align: right;
  min-width: 3.25rem;
}

.funnel-stage-row--sub {
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 2.2fr) auto;
  opacity: 0.95;
}

.funnel-stage-row--sub .funnel-stage-label {
  font-size: 0.72rem;
  color: #c4b5fd;
  padding-left: 0.65rem;
  border-left: 2px solid rgba(196, 181, 253, 0.45);
}

.funnel-stage-row--sub .funnel-stage-value {
  font-size: 0.8rem;
  font-weight: 500;
  color: #d8ccf9;
}

.funnel-stage-row--sub .funnel-stage-bar {
  min-height: 6px;
  opacity: 0.55;
}

.funnel-stage-bar--sub {
  background: linear-gradient(90deg, rgba(196, 181, 253, 0.35), rgba(139, 92, 246, 0.25));
}

.funnel-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}

@media (min-width: 900px) {
  .funnel-grid {
    grid-template-columns: 1fr 1fr;
  }

  .funnel-card-wide {
    grid-column: 1 / -1;
  }
}

.funnel-card {
  background: linear-gradient(165deg, var(--surface) 0%, #121a28 100%);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1rem 1.15rem 1.15rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

.funnel-card-title {
  margin: 0 0 0.35rem;
  font-size: 0.95rem;
  font-weight: 600;
}

.funnel-card-desc {
  margin: 0 0 0.75rem;
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.45;
}

.funnel-chart-wrap {
  position: relative;
  height: 240px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.18);
  border: 1px solid var(--border);
  padding: 0.35rem;
}

.funnel-chart-tall {
  height: 300px;
}

/* Gráfico 1 — largura total da grelha + altura confortável */
.funnel-chart-wrap-main {
  height: min(340px, 42vh);
}

.store-dialog {
  margin: auto;
  max-width: min(1080px, 96vw);
  width: 100%;
  max-height: 94vh;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
  padding: 0;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
  overflow: auto;
  overflow-x: hidden;
}

.store-dialog::backdrop {
  background: rgba(0, 0, 0, 0.65);
}

.store-dialog-panel {
  padding: 1rem 1.15rem 1.2rem;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.auto-dialog-panel {
  max-width: none;
  max-height: none;
  overflow: visible;
}

.auto-steps {
  display: grid;
  gap: 0.85rem;
  overflow: visible;
  min-width: 0;
}

.auto-step-title {
  margin: 0 0 0.25rem;
  font-size: 0.95rem;
  font-weight: 600;
}

.auto-step-desc {
  margin: 0 0 0.75rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.auto-card {
  background: rgba(0, 0, 0, 0.18);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.85rem 0.95rem;
  min-width: 0;
}

.auto-card-title {
  margin: 0 0 0.15rem;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.auto-card-desc {
  margin: 0 0 0.7rem;
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.4;
}

.auto-grid--inner {
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem 0.75rem;
}

.auto-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem 1rem;
  min-width: 0;
}

.auto-grid .period-date,
.auto-grid .period-select {
  width: 100%;
}

.auto-checks {
  display: grid;
  gap: 0.35rem;
}

.auto-checks label {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  font-size: 0.85rem;
  color: #c5d2e3;
}

.auto-checks--toggles {
  gap: 0.55rem;
}

.auto-toggle {
  display: grid !important;
  grid-template-columns: 44px 1fr;
  gap: 0.65rem;
  align-items: center;
  padding: 0.45rem 0.55rem;
  border-radius: 10px;
  border: 1px solid rgba(42, 58, 82, 0.75);
  background: rgba(0, 0, 0, 0.12);
}

.auto-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.auto-toggle-ui {
  width: 44px;
  height: 24px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.25);
  position: relative;
  box-shadow: inset 0 1px 10px rgba(0, 0, 0, 0.35);
}

.auto-toggle-ui::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  transform: translateY(-50%);
  background: #94a3b8;
  transition: left 0.15s ease, background 0.15s ease;
}

.auto-toggle input:checked + .auto-toggle-ui {
  background: rgba(99, 179, 255, 0.18);
  border-color: rgba(99, 179, 255, 0.45);
}

.auto-toggle input:checked + .auto-toggle-ui::after {
  left: 22px;
  background: #63b3ff;
}

.auto-toggle-text {
  font-size: 0.86rem;
  color: #d7e3f3;
}

.auto-footer {
  justify-content: space-between;
  margin-top: 0.85rem;
  flex-shrink: 0;
}

.auto-progress {
  display: grid;
  gap: 0.5rem;
}

.auto-progress-bar {
  height: 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.25);
  overflow: hidden;
}

.auto-progress-bar > div {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #63b3ff, #34d399);
  transition: width 0.25s ease;
}

@media (max-width: 720px) {
  .auto-grid {
    grid-template-columns: 1fr;
  }
  .auto-grid--inner {
    grid-template-columns: 1fr;
  }
  .header-actions {
    width: 100%;
    justify-content: flex-start;
  }
  .store-dialog-panel {
    padding: 0.85rem 0.9rem 1rem;
  }
}

.store-dialog-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
}

.store-dialog-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
}

.store-dialog-close {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.store-dialog-close:hover {
  background: var(--border);
}

.store-dialog-sub {
  margin: 0 0 0.85rem;
  font-size: 0.8rem;
  color: var(--muted);
}

.store-link-list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: min(52vh, 420px);
  overflow-y: auto;
}

.store-link-list li {
  border-bottom: 1px solid var(--border);
  padding: 0.55rem 0;
}

.store-link-group {
  padding: 0.75rem 0 0.35rem;
  border-bottom: 1px solid rgba(42, 58, 82, 0.55);
}

.store-link-list li:last-child {
  border-bottom: none;
}

.store-link-list a.store-open-link {
  display: inline-block;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
  margin-bottom: 0.2rem;
}

.store-link-list a.store-open-link:hover {
  text-decoration: underline;
}

.store-link-meta {
  display: block;
  font-size: 0.75rem;
  color: var(--muted);
}

.store-dialog-empty {
  margin: 0;
  font-size: 0.875rem;
  color: var(--muted);
}

.stores-panel {
  margin-top: 1.75rem;
  padding: 1.15rem 1.25rem 1.25rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.stores-panel-title {
  margin: 0 0 0.35rem;
  font-size: 1rem;
  font-weight: 600;
}

.stores-panel-desc {
  margin: 0 0 1rem;
  font-size: 0.8rem;
  color: var(--muted);
}

.stores-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  margin-bottom: 0.65rem;
}

.login-form {
  display: grid;
  gap: 0.5rem;
  max-width: 420px;
}

.login-form .action-btn.primary {
  justify-self: start;
  margin-top: 0.25rem;
}

@media (max-width: 720px) {
  /* KPIs usados também em painéis internos (intend) */
  .stores-panel .kpi-row .kpi-card {
    flex: 1 1 100%;
  }
}

.stores-label {
  font-size: 0.75rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.list-caption {
  margin: 0 0 0.65rem;
  font-size: 0.8rem;
  color: #a8b8cc;
}

.table-scroll {
  overflow-x: auto;
  border-radius: 10px;
  border: 1px solid var(--border);
}

.stores-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
}

.stores-table th,
.stores-table td {
  padding: 0.55rem 0.65rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.stores-table th {
  background: rgba(0, 0, 0, 0.25);
  color: var(--muted);
  font-weight: 600;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.stores-table tbody tr:hover {
  background: rgba(99, 179, 255, 0.06);
}

.table-empty {
  text-align: center;
  color: var(--muted);
  padding: 1.25rem !important;
}

.table-link {
  color: var(--accent);
  text-decoration: none;
}

.table-link:hover {
  text-decoration: underline;
}

.plan-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.2rem 0.45rem;
  border-radius: 6px;
  white-space: nowrap;
}

.plan-badge--pro {
  color: #c4b5fd;
  background: rgba(139, 92, 246, 0.2);
  border: 1px solid rgba(139, 92, 246, 0.35);
}

.plan-badge--free {
  color: var(--muted);
  background: var(--surface-2);
  border: 1px solid var(--border);
}

.error {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  background: #3d1f24;
  border: 1px solid #8b2e3a;
  border-radius: 8px;
  color: #f5b5bc;
}
