:root {
  --v2-primary: #2563eb;
  --v2-primary-hover: #1d4ed8;
  --v2-primary-soft: #dbeafe;
  --v2-sidebar: #0b1c30;
  --v2-sidebar-top: #213145;
  --v2-sidebar-hover: #172b44;
  --v2-canvas: #f8f9ff;
  --v2-surface: #ffffff;
  --v2-surface-muted: #f1f5f9;
  --v2-border: #e2e8f0;
  --v2-border-strong: #cbd5e1;
  --v2-text: #0f172a;
  --v2-text-muted: #64748b;
  --v2-success: #15803d;
  --v2-warning: #b45309;
  --v2-danger: #b91c1c;
  --v2-sidebar-width: 256px;
  --v2-topbar-height: 64px;
  color-scheme: light;
}

body.dashboard-v2 {
  min-height: 100vh;
  background: var(--v2-canvas) !important;
  color: var(--v2-text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  accent-color: var(--v2-primary);
}

body.dashboard-v2 ::selection {
  background: #bfdbfe;
  color: #0b1c30;
}

body.dashboard-v2 * {
  scrollbar-color: #94a3b8 transparent;
  scrollbar-width: thin;
}

body.dashboard-v2 *::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

body.dashboard-v2 *::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: #94a3b8;
  background-clip: padding-box;
}

body.dashboard-v2 h1,
body.dashboard-v2 h2,
body.dashboard-v2 h3,
body.dashboard-v2 h4,
body.dashboard-v2 .dashboard-metric-card > p:nth-child(2) {
  font-family: "Plus Jakarta Sans", Inter, ui-sans-serif, system-ui, sans-serif;
  letter-spacing: -0.025em;
}

body.dashboard-v2 a,
body.dashboard-v2 button,
body.dashboard-v2 input,
body.dashboard-v2 select,
body.dashboard-v2 textarea {
  -webkit-tap-highlight-color: transparent;
}

body.dashboard-v2 :where(a, button, input, select, textarea, [tabindex]):focus-visible {
  outline: 2px solid var(--v2-primary) !important;
  outline-offset: 2px !important;
  box-shadow: 0 0 0 4px rgb(37 99 235 / 0.16) !important;
}

body.dashboard-v2 :where(input, textarea)::placeholder {
  color: #64748b !important;
  opacity: 1;
}

body.dashboard-v2 .material-symbols-outlined {
  font-family: "Material Symbols Outlined";
  font-weight: 400;
  font-style: normal;
  font-size: 20px;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-block;
  white-space: nowrap;
  word-wrap: normal;
  direction: ltr;
  -webkit-font-feature-settings: "liga";
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "liga";
}

/* Application shell */
body.dashboard-v2 .dashboard-topbar {
  position: fixed !important;
  inset: 0 0 auto var(--v2-sidebar-width) !important;
  z-index: 50 !important;
  height: var(--v2-topbar-height);
  border-bottom: 1px solid var(--v2-border) !important;
  background: rgb(255 255 255 / 0.94) !important;
  box-shadow: 0 1px 8px rgb(15 23 42 / 0.05) !important;
  backdrop-filter: blur(14px);
}

body.dashboard-v2 .dashboard-topbar-content {
  position: relative;
  width: 100%;
  max-width: none !important;
  height: var(--v2-topbar-height);
  padding: 0 24px !important;
}

body.dashboard-v2 .dashboard-topbar .dashboard-public-link {
  min-height: 34px !important;
  border-radius: 999px !important;
  background: var(--v2-sidebar) !important;
  padding: 7px 13px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  box-shadow: none !important;
}

body.dashboard-v2 .dashboard-topbar .dashboard-platform-logo {
  position: absolute;
  left: 50%;
  margin: 0 !important;
  transform: translateX(-50%);
}

body.dashboard-v2 .dashboard-topbar .dashboard-platform-logo img {
  height: 34px !important;
  width: auto;
}

body.dashboard-v2 .store-reseller-identity {
  margin-left: auto !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.dashboard-v2 :is(main, div):has(> .dashboard-sidebar) {
  display: block !important;
  width: 100% !important;
  min-height: 100vh;
  max-width: none !important;
  margin: 0 !important;
  padding: calc(var(--v2-topbar-height) + 24px) 24px 32px calc(var(--v2-sidebar-width) + 24px) !important;
  background: var(--v2-canvas) !important;
}

body.dashboard-v2 :is(main, div):has(> .dashboard-sidebar) > section {
  width: 100%;
  min-width: 0;
  max-width: 1600px;
  margin: 0 auto;
}

body.dashboard-v2.dashboard-sidebar-collapsed {
  --v2-sidebar-width: 76px;
}

/* Sidebar */
body.dashboard-v2 .dashboard-sidebar {
  position: fixed !important;
  inset: 0 auto 0 0 !important;
  z-index: 70 !important;
  display: flex !important;
  flex-direction: column;
  width: var(--v2-sidebar-width) !important;
  max-width: none !important;
  height: 100vh;
  padding: 0 !important;
  overflow: hidden !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: var(--v2-sidebar) !important;
  box-shadow: 2px 0 12px rgb(15 23 42 / 0.08) !important;
  color: #f8fafc;
  transition: transform 180ms cubic-bezier(.16, 1, .3, 1);
}

body.dashboard-v2 .dashboard-sidebar > .js-dashboard-sidebar-toggle,
body.dashboard-v2 .dashboard-sidebar > .js-dashboard-menu-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 3;
  width: 38px !important;
  height: 38px !important;
  margin: 0 !important;
  border: 0 !important;
  border-radius: 8px !important;
  background: transparent !important;
  color: #cbd5e1 !important;
  box-shadow: none !important;
}

body.dashboard-v2 .dashboard-sidebar > .js-dashboard-sidebar-toggle:hover,
body.dashboard-v2 .dashboard-sidebar > .js-dashboard-menu-close:hover {
  background: rgb(255 255 255 / 0.08) !important;
  color: #fff !important;
}

body.dashboard-v2 .dashboard-sidebar-profile,
body.dashboard-v2 .dashboard-sidebar > .flex.items-center.gap-3 {
  flex: 0 0 var(--v2-topbar-height);
  width: 100%;
  min-height: var(--v2-topbar-height);
  margin: 0 !important;
  padding: 11px 56px 11px 14px !important;
  overflow: hidden;
  border: 0 !important;
  border-radius: 0 !important;
  background: var(--v2-sidebar-top) !important;
  box-shadow: none !important;
}

body.dashboard-v2 .dashboard-sidebar-profile > .flex {
  height: 100%;
}

body.dashboard-v2 .dashboard-sidebar-profile form,
body.dashboard-v2 .dashboard-sidebar > .flex.items-center.gap-3 form {
  width: 38px !important;
  height: 38px !important;
  border-radius: 9px !important;
  background: var(--v2-primary) !important;
  color: #fff !important;
  font-size: 15px !important;
}

body.dashboard-v2 .dashboard-sidebar-profile p,
body.dashboard-v2 .dashboard-sidebar > .flex.items-center.gap-3 p {
  color: #b4c5ff !important;
  font-size: 10px !important;
  font-weight: 700 !important;
  letter-spacing: .08em !important;
}

body.dashboard-v2 .dashboard-sidebar-profile h1,
body.dashboard-v2 .dashboard-sidebar > .flex.items-center.gap-3 h1 {
  color: #fff !important;
  font-family: "Plus Jakarta Sans", Inter, sans-serif;
  font-size: 14px !important;
  font-weight: 700 !important;
  letter-spacing: -.015em;
}

body.dashboard-v2 .dashboard-sidebar nav {
  flex: 1 1 auto;
  margin: 0 !important;
  padding: 8px !important;
  overflow-x: hidden;
  overflow-y: auto;
  scrollbar-color: #475569 transparent;
}

body.dashboard-v2 .dashboard-sidebar nav.space-y-2 > :not([hidden]) ~ :not([hidden]) {
  margin-top: 2px !important;
}

body.dashboard-v2 .dashboard-sidebar-link {
  display: flex !important;
  min-height: 36px !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 11px !important;
  border: 0 !important;
  border-radius: 8px !important;
  padding: 8px 10px !important;
  color: #cbd5e1 !important;
  font-family: Inter, sans-serif;
  font-size: 12px !important;
  font-weight: 500 !important;
  line-height: 16px !important;
  text-align: left;
  box-shadow: none !important;
  transition: background-color 150ms ease, color 150ms ease;
}

body.dashboard-v2 .dashboard-sidebar-link:hover {
  background: var(--v2-sidebar-hover) !important;
  color: #fff !important;
}

body.dashboard-v2 .dashboard-sidebar-link--active,
body.dashboard-v2 .dashboard-sidebar-link[aria-current="page"] {
  background: var(--v2-primary) !important;
  color: #fff !important;
  font-weight: 650 !important;
}

body.dashboard-v2 .dashboard-sidebar-icon {
  display: inline-grid !important;
  width: 20px !important;
  height: 20px !important;
  flex: 0 0 20px;
  place-items: center;
  border-radius: 0 !important;
  background: transparent !important;
  color: currentColor;
  font-size: 19px !important;
}

body.dashboard-v2 .dashboard-sidebar-label {
  min-width: 0;
  flex: 1 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.dashboard-v2 .dashboard-sidebar > form {
  flex: 0 0 auto;
  margin: 0 !important;
  padding: 8px !important;
  border-top: 1px solid rgb(148 163 184 / 0.15);
  background: var(--v2-sidebar-top);
}

body.dashboard-v2 .dashboard-sidebar > form .dashboard-sidebar-link {
  width: 100%;
  margin: 0 !important;
  background: transparent !important;
}

body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar-profile,
body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar > .flex.items-center.gap-3 {
  padding-inline: 18px !important;
}

body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar-profile h1,
body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar-profile p,
body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar > .flex.items-center.gap-3 h1,
body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar > .flex.items-center.gap-3 p,
body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar-label,
body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar-link > span:not(.dashboard-sidebar-icon) {
  display: none !important;
}

body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar > .js-dashboard-sidebar-toggle {
  top: 74px;
  right: 19px;
}

body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar nav {
  padding-top: 54px !important;
}

body.dashboard-v2.dashboard-sidebar-collapsed .dashboard-sidebar-link {
  justify-content: center !important;
  padding-inline: 8px !important;
}

/* Shared workspace surfaces */
body.dashboard-v2 :is(main, div):has(> .dashboard-sidebar) > section > :first-child {
  margin-top: 0 !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) .rounded-3xl,
body.dashboard-v2 div:has(> .dashboard-sidebar) .rounded-3xl {
  border-radius: 12px !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) .rounded-2xl,
body.dashboard-v2 div:has(> .dashboard-sidebar) .rounded-2xl {
  border-radius: 8px !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) :is(.shadow-sm, .shadow-xl, .shadow-2xl),
body.dashboard-v2 div:has(> .dashboard-sidebar) :is(.shadow-sm, .shadow-xl, .shadow-2xl) {
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.05) !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) :is(article, section, header, aside, div).border-slate-200,
body.dashboard-v2 div:has(> .dashboard-sidebar) :is(article, section, header, aside, div).border-slate-200 {
  border-color: var(--v2-border) !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]), select, textarea),
body.dashboard-v2 div:has(> .dashboard-sidebar) :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]), select, textarea) {
  border-color: var(--v2-border-strong) !important;
  border-radius: 8px !important;
  background: #fff !important;
  color: var(--v2-text) !important;
  font-family: Inter, sans-serif !important;
  font-weight: 500 !important;
  box-shadow: none !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) :is(input, select, textarea):focus,
body.dashboard-v2 div:has(> .dashboard-sidebar) :is(input, select, textarea):focus {
  border-color: var(--v2-primary) !important;
  outline: 0 !important;
  box-shadow: 0 0 0 3px rgb(37 99 235 / 0.14) !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) button:not(.js-dashboard-menu-open):not(.js-dashboard-menu-close):not(.js-dashboard-sidebar-toggle),
body.dashboard-v2 main:has(> .dashboard-sidebar) a[class*="rounded"] {
  border-radius: 8px !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="bg-indigo-600"],
body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="bg-violet-600"] {
  background-color: var(--v2-primary) !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="hover:bg-indigo-700"]:hover,
body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="hover:bg-violet-700"]:hover {
  background-color: var(--v2-primary-hover) !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="text-indigo-600"],
body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="text-indigo-700"],
body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="text-violet-600"] {
  color: var(--v2-primary) !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="bg-indigo-50"],
body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="bg-violet-50"] {
  background-color: #eff6ff !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="border-indigo-"],
body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="border-violet-"] {
  border-color: #bfdbfe !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="ring-indigo-"],
body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="ring-violet-"] {
  --tw-ring-color: rgb(37 99 235 / 0.18) !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) [class*="bg-slate-950"] {
  background-color: var(--v2-sidebar) !important;
}

/* Dashboard and catalog patterns */
body.dashboard-v2 .dashboard-metrics {
  gap: 14px !important;
}

body.dashboard-v2 .dashboard-metric-card {
  min-height: 118px;
  border: 1px solid var(--v2-border) !important;
  border-radius: 12px !important;
  background: #fff !important;
  padding: 18px !important;
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.05) !important;
}

body.dashboard-v2 .dashboard-metric-card > p:first-child {
  color: #475569 !important;
  font-size: 12px !important;
  font-weight: 500 !important;
}

body.dashboard-v2 .dashboard-metric-card > p:nth-child(2) {
  margin-top: 8px !important;
  color: var(--v2-text) !important;
  font-size: 28px !important;
  font-weight: 800 !important;
  line-height: 34px !important;
}

body.dashboard-v2 .dashboard-metric-card > p:last-child {
  margin-top: 7px !important;
  color: var(--v2-primary) !important;
  font-size: 11px !important;
  font-weight: 600 !important;
}

body.dashboard-v2 .dashboard-chart-canvas {
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background-color: #eff6ff !important;
  background-image: linear-gradient(#dbeafe 1px, transparent 1px), linear-gradient(90deg, #dbeafe 1px, transparent 1px);
  background-size: 100% 25%, 16.666% 100%;
}

body.dashboard-v2 .dashboard-product-list-header,
body.dashboard-v2 .dashboard-product-card {
  border-color: var(--v2-border) !important;
  background: #fff !important;
}

body.dashboard-v2 .dashboard-product-card {
  padding-block: 14px !important;
  transition: background-color 150ms ease;
}

body.dashboard-v2 .dashboard-product-card:hover {
  background: #f8fafc !important;
}

body.dashboard-v2 .dashboard-product-image {
  border: 1px solid var(--v2-border) !important;
  border-radius: 8px !important;
  background: #f8fafc !important;
}

body.dashboard-v2 .dashboard-product-badges > span {
  border-radius: 999px !important;
  font-size: 11px !important;
  font-weight: 600 !important;
}

body.dashboard-v2 table {
  border-collapse: separate;
  border-spacing: 0;
  font-size: 13px;
}

body.dashboard-v2 thead {
  background: #f8fafc;
  color: #64748b;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
}

body.dashboard-v2 tbody tr {
  transition: background-color 140ms ease;
}

body.dashboard-v2 tbody tr:hover {
  background: #f8fafc;
}

body.dashboard-v2 th,
body.dashboard-v2 td {
  border-color: var(--v2-border) !important;
}

/* Affiliate portal: Stitch visual language over the existing affiliate contracts. */
body.dashboard-v2 .affiliate-portal-shell {
  min-height: 100vh;
  background: var(--v2-canvas);
}

body.dashboard-v2 .affiliate-topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--v2-border);
  background: rgb(248 249 255 / 0.94);
  box-shadow: 0 1px 8px rgb(15 23 42 / 0.04);
  backdrop-filter: blur(14px);
}

body.dashboard-v2 .affiliate-topbar__inner {
  display: flex;
  width: min(100%, 1280px);
  min-height: 64px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin: 0 auto;
  padding: 0 24px;
}

body.dashboard-v2 .affiliate-topbar__start,
body.dashboard-v2 .affiliate-account,
body.dashboard-v2 .affiliate-tabs {
  display: flex;
  align-items: center;
}

body.dashboard-v2 .affiliate-topbar__start {
  min-width: 0;
  gap: 28px;
}

body.dashboard-v2 .affiliate-brand {
  display: flex;
  min-height: 40px;
  min-width: max-content;
  flex-direction: column;
  justify-content: center;
  color: var(--v2-text);
  line-height: 1.1;
  text-decoration: none;
}

body.dashboard-v2 .affiliate-brand__name {
  color: var(--v2-primary);
  font-family: "Plus Jakarta Sans", Inter, sans-serif;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -.025em;
}

body.dashboard-v2 .affiliate-brand__section {
  margin-top: 3px;
  color: var(--v2-text-muted);
  font-size: 10px;
  font-weight: 600;
}

body.dashboard-v2 .affiliate-tabs {
  gap: 4px;
}

body.dashboard-v2 .affiliate-tab {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  padding: 8px 13px;
  color: #475569;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 150ms ease, color 150ms ease;
}

body.dashboard-v2 .affiliate-tab:hover {
  background: #eff4ff;
  color: var(--v2-text);
}

body.dashboard-v2 .affiliate-tab--active,
body.dashboard-v2 .affiliate-tab[aria-current="page"] {
  background: #dce9ff;
  color: var(--v2-primary-hover);
}

body.dashboard-v2 .affiliate-tabs--mobile {
  display: none;
}

body.dashboard-v2 .affiliate-account {
  min-width: 0;
  gap: 10px;
}

body.dashboard-v2 .affiliate-icon-button,
body.dashboard-v2 .affiliate-logout {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #475569;
  cursor: pointer;
  transition: background-color 150ms ease, color 150ms ease;
}

body.dashboard-v2 .affiliate-icon-button {
  position: relative;
  width: 40px;
}

body.dashboard-v2 .affiliate-icon-button:hover,
body.dashboard-v2 .affiliate-logout:hover {
  background: #eff4ff;
  color: var(--v2-primary);
}

body.dashboard-v2 .affiliate-notification-count {
  position: absolute;
  top: 3px;
  right: 2px;
  display: grid;
  min-width: 17px;
  height: 17px;
  place-items: center;
  border: 2px solid #f8f9ff;
  border-radius: 999px;
  background: #e11d48;
  padding: 0 3px;
  color: #fff;
  font-size: 9px;
  font-weight: 800;
  line-height: 1;
}

body.dashboard-v2 .affiliate-avatar {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  border-radius: 999px;
  background: var(--v2-primary);
  color: #fff;
  font-family: "Plus Jakarta Sans", Inter, sans-serif;
  font-size: 13px;
  font-weight: 800;
}

body.dashboard-v2 .affiliate-account__name {
  max-width: 140px;
  overflow: hidden;
  color: var(--v2-text);
  font-size: 12px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.dashboard-v2 .affiliate-logout {
  gap: 5px;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 600;
}

body.dashboard-v2 .affiliate-logout .material-symbols-outlined {
  font-size: 18px;
}

body.dashboard-v2 .affiliate-workspace {
  width: min(100%, 1280px);
  margin: 0 auto;
  padding: 24px 24px 48px;
}

body.dashboard-v2 .affiliate-hero {
  position: relative;
  min-height: 174px;
  overflow: hidden;
  border-radius: 12px;
  background: linear-gradient(112deg, #004ac6 0%, #2563eb 58%, #0053db 100%);
  box-shadow: 0 8px 18px rgb(37 99 235 / 0.16);
  color: #fff;
}

body.dashboard-v2 .affiliate-hero__content {
  position: relative;
  z-index: 1;
  display: flex;
  min-height: 174px;
  max-width: 720px;
  flex-direction: column;
  justify-content: center;
  padding: 30px 32px;
}

body.dashboard-v2 .affiliate-hero h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(26px, 3vw, 34px);
  font-weight: 700;
  line-height: 1.18;
}

body.dashboard-v2 .affiliate-hero p {
  max-width: 620px;
  margin: 10px 0 0;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.55;
}

body.dashboard-v2 .affiliate-hero__glow {
  position: absolute;
  border-radius: 999px;
  pointer-events: none;
}

body.dashboard-v2 .affiliate-hero__glow--one {
  top: -130px;
  right: -60px;
  width: 390px;
  height: 390px;
  background: rgb(255 255 255 / 0.1);
  filter: blur(24px);
}

body.dashboard-v2 .affiliate-hero__glow--two {
  right: 32%;
  bottom: -150px;
  width: 290px;
  height: 290px;
  background: rgb(127 252 151 / 0.13);
  filter: blur(26px);
}

body.dashboard-v2 .affiliate-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

body.dashboard-v2 .affiliate-metric-card {
  min-width: 0;
  min-height: 128px;
  border: 1px solid var(--v2-border);
  border-radius: 12px;
  background: #fff;
  padding: 18px;
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.05);
}

body.dashboard-v2 .affiliate-metric-card__heading {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .045em;
  text-transform: uppercase;
}

body.dashboard-v2 .affiliate-metric-card__icon {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  border-radius: 8px;
  background: #e5eeff;
  color: var(--v2-primary);
  font-size: 20px !important;
}

body.dashboard-v2 .affiliate-metric-card--green .affiliate-metric-card__icon {
  background: #dcfce7;
  color: #047857;
}

body.dashboard-v2 .affiliate-metric-card--violet .affiliate-metric-card__icon {
  background: #e3dfff;
  color: #514f81;
}

body.dashboard-v2 .affiliate-metric-card strong {
  display: block;
  margin-top: 18px;
  overflow-wrap: anywhere;
  color: var(--v2-text);
  font-family: "Plus Jakarta Sans", Inter, sans-serif;
  font-size: 27px;
  font-weight: 800;
  letter-spacing: -.035em;
  line-height: 1.15;
}

body.dashboard-v2 .affiliate-metric-card--green strong {
  color: #047857;
}

body.dashboard-v2 .affiliate-stores {
  margin-top: 32px;
}

body.dashboard-v2 .affiliate-section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

body.dashboard-v2 .affiliate-section-heading h2 {
  margin: 0;
  color: var(--v2-text);
  font-size: 23px;
  font-weight: 700;
}

body.dashboard-v2 .affiliate-section-heading p {
  margin: 5px 0 0;
  color: var(--v2-text-muted);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.45;
}

body.dashboard-v2 .affiliate-section-heading > span {
  flex: 0 0 auto;
  border-radius: 999px;
  background: #dce9ff;
  padding: 5px 10px;
  color: var(--v2-primary-hover);
  font-size: 11px;
  font-weight: 700;
}

body.dashboard-v2 .affiliate-store-list {
  display: grid;
  gap: 16px;
}

body.dashboard-v2 .affiliate-store-card,
body.dashboard-v2 .affiliate-empty-state {
  border: 1px solid var(--v2-border);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.05);
}

body.dashboard-v2 .affiliate-store-card {
  padding: 22px;
}

body.dashboard-v2 .affiliate-store-card__header,
body.dashboard-v2 .affiliate-store-card__identity {
  display: flex;
  align-items: center;
}

body.dashboard-v2 .affiliate-store-card__header {
  justify-content: space-between;
  gap: 16px;
}

body.dashboard-v2 .affiliate-store-card__identity {
  min-width: 0;
  gap: 12px;
}

body.dashboard-v2 .affiliate-store-card__icon {
  display: grid;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  place-items: center;
  border-radius: 10px;
  background: #e5eeff;
  color: var(--v2-primary);
  font-size: 23px !important;
}

body.dashboard-v2 .affiliate-store-card__identity p {
  margin: 0;
  color: var(--v2-text-muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}

body.dashboard-v2 .affiliate-store-card__identity h3 {
  margin: 3px 0 0;
  overflow: hidden;
  color: var(--v2-text);
  font-size: 18px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.dashboard-v2 .affiliate-store-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin: 20px 0 0;
  border-block: 1px solid #e5eeff;
  padding: 17px 0;
}

body.dashboard-v2 .affiliate-store-stats > div {
  min-width: 0;
  padding: 0 16px;
  border-left: 1px solid #e5eeff;
}

body.dashboard-v2 .affiliate-store-stats > div:first-child {
  padding-left: 0;
  border-left: 0;
}

body.dashboard-v2 .affiliate-store-stats dt {
  color: var(--v2-text-muted);
  font-size: 11px;
  font-weight: 600;
}

body.dashboard-v2 .affiliate-store-stats dd {
  margin: 5px 0 0;
  overflow-wrap: anywhere;
  color: var(--v2-text);
  font-family: "Plus Jakarta Sans", Inter, sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.25;
}

body.dashboard-v2 .affiliate-share-field {
  margin-top: 20px;
}

body.dashboard-v2 .affiliate-share-field > span {
  display: block;
  margin-bottom: 7px;
  color: var(--v2-text);
  font-size: 12px;
  font-weight: 600;
}

body.dashboard-v2 .affiliate-share-field > div {
  position: relative;
}

body.dashboard-v2 .affiliate-share-field input {
  width: 100%;
  height: 44px;
  border: 1px solid var(--v2-border) !important;
  border-radius: 8px !important;
  background: #f8f9ff !important;
  padding: 0 40px 0 13px;
  color: #334155 !important;
  font-family: Inter, monospace !important;
  font-size: 12px !important;
  font-weight: 500 !important;
}

body.dashboard-v2 .affiliate-share-field .material-symbols-outlined {
  position: absolute;
  top: 13px;
  right: 13px;
  color: #94a3b8;
  font-size: 18px;
  pointer-events: none;
}

body.dashboard-v2 .affiliate-store-actions {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  margin-top: 11px;
}

body.dashboard-v2 .affiliate-primary-action,
body.dashboard-v2 .affiliate-secondary-action {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border-radius: 8px;
  padding: 0 16px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease;
}

body.dashboard-v2 .affiliate-primary-action {
  border: 1px solid var(--v2-primary);
  background: var(--v2-primary);
  color: #fff;
}

body.dashboard-v2 .affiliate-primary-action:hover {
  border-color: var(--v2-primary-hover);
  background: var(--v2-primary-hover);
}

body.dashboard-v2 .affiliate-secondary-action {
  border: 1px solid #bfdbfe;
  background: #eff4ff;
  color: var(--v2-primary);
  cursor: pointer;
}

body.dashboard-v2 .affiliate-secondary-action:hover {
  border-color: #93c5fd;
  background: #dce9ff;
}

body.dashboard-v2 .affiliate-primary-action .material-symbols-outlined,
body.dashboard-v2 .affiliate-secondary-action .material-symbols-outlined {
  font-size: 17px;
}

body.dashboard-v2 .affiliate-store-pending {
  margin: 18px 0 0;
  border-radius: 8px;
  background: #eff4ff;
  padding: 12px 14px;
  color: #475569;
  font-size: 12px;
  font-weight: 600;
}

body.dashboard-v2 .affiliate-empty-state {
  padding: 42px 24px;
  text-align: center;
}

body.dashboard-v2 .affiliate-empty-state > .material-symbols-outlined {
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  margin: 0 auto 12px;
  border-radius: 12px;
  background: #e5eeff;
  color: var(--v2-primary);
  font-size: 28px;
}

body.dashboard-v2 .affiliate-empty-state h3 {
  margin: 0;
  color: var(--v2-text);
  font-size: 16px;
  font-weight: 700;
}

body.dashboard-v2 .affiliate-empty-state p {
  max-width: 560px;
  margin: 7px auto 0;
  color: var(--v2-text-muted);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.55;
}

/* Sensitive editors: visual changes only, preserve their layout and controls. */
body.dashboard-v2 #page-layout-editor,
body.dashboard-v2 #quote-editor,
body.dashboard-v2 form:has(#quoteProductSearch) {
  isolation: isolate;
}

body.dashboard-v2 #page-layout-editor .pe-preview-shell,
body.dashboard-v2 #quote-editor .qe-preview-shell {
  border-radius: 12px !important;
  background: var(--v2-sidebar) !important;
  box-shadow: 0 10px 15px -3px rgb(15 23 42 / 0.12), 0 4px 6px -4px rgb(15 23 42 / 0.08) !important;
}

body.dashboard-v2 #page-layout-editor .js-layout-block {
  border-color: var(--v2-border) !important;
  background: #f8fafc !important;
}

body.dashboard-v2 #page-layout-editor .js-layout-block:active {
  border-color: #93c5fd !important;
  background: #eff6ff !important;
}

body.dashboard-v2 #quote-editor .qe-tab-active {
  border-color: var(--v2-primary) !important;
  color: var(--v2-primary) !important;
}

body.dashboard-v2 .sticky.bottom-4 {
  border-color: var(--v2-border) !important;
  background: rgb(255 255 255 / 0.96) !important;
  box-shadow: 0 10px 15px -3px rgb(15 23 42 / 0.1), 0 4px 6px -4px rgb(15 23 42 / 0.05) !important;
}

body.dashboard-v2 main:has(> .dashboard-sidebar) > section {
  animation: dashboard-v2-enter 360ms cubic-bezier(.16, 1, .3, 1) both;
}

@keyframes dashboard-v2-enter {
  from { transform: translateY(4px); filter: saturate(.96); }
  to { transform: translateY(0); filter: saturate(1); }
}

@media (max-width: 1023px) {
  :root {
    --v2-sidebar-width: 0px;
  }

  body.dashboard-v2 .dashboard-topbar {
    left: 0 !important;
  }

  body.dashboard-v2 .dashboard-topbar-content {
    padding-inline: 12px !important;
  }

  body.dashboard-v2 .dashboard-topbar .dashboard-platform-logo {
    position: static;
    margin-left: auto !important;
    transform: none;
  }

  body.dashboard-v2 :is(main, div):has(> .dashboard-sidebar) {
    padding: calc(var(--v2-topbar-height) + 16px) 14px 28px !important;
  }

  body.dashboard-v2 .dashboard-sidebar {
    display: flex !important;
    width: min(286px, 88vw) !important;
    transform: translateX(-102%);
    box-shadow: 16px 0 36px rgb(15 23 42 / 0.24) !important;
  }

  body.dashboard-v2.dashboard-mobile-menu-open .dashboard-sidebar {
    transform: translateX(0);
  }

  body.dashboard-v2.dashboard-mobile-menu-open::after {
    z-index: 60 !important;
    background: rgb(11 28 48 / 0.58) !important;
    backdrop-filter: blur(2px);
  }

  body.dashboard-v2 .dashboard-sidebar > .js-dashboard-menu-close {
    display: grid !important;
  }

  body.dashboard-v2 .dashboard-topbar .dashboard-topbar-menu {
    display: grid !important;
    width: 40px !important;
    height: 40px !important;
    min-height: 40px !important;
    border-radius: 8px !important;
    background: var(--v2-sidebar) !important;
  }

  body.dashboard-v2 .dashboard-topbar .dashboard-public-link {
    max-width: 132px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body.dashboard-v2 main:has(> .dashboard-sidebar) .overflow-x-auto {
    margin-inline: -2px;
    padding-bottom: 6px;
  }
}

@media (max-width: 767px) {
  body.dashboard-v2 {
    font-size: 13px;
  }

  body.dashboard-v2 .dashboard-topbar .dashboard-platform-logo {
    display: none !important;
  }

  body.dashboard-v2 :is(main, div):has(> .dashboard-sidebar) > section.space-y-6 > * + *,
  body.dashboard-v2 :is(main, div):has(> .dashboard-sidebar) > section.space-y-5 > * + * {
    margin-top: 14px !important;
  }

  body.dashboard-v2 main:has(> .dashboard-sidebar) .rounded-3xl,
  body.dashboard-v2 div:has(> .dashboard-sidebar) .rounded-3xl {
    border-radius: 10px !important;
  }

  body.dashboard-v2 main:has(> .dashboard-sidebar) > section > header,
  body.dashboard-v2 main:has(> .dashboard-sidebar) > section > article,
  body.dashboard-v2 main:has(> .dashboard-sidebar) > section > .rounded-3xl {
    padding: 16px !important;
  }

  body.dashboard-v2 .dashboard-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  body.dashboard-v2 .dashboard-metric-card {
    min-height: 102px;
    padding: 14px !important;
  }

  body.dashboard-v2 .dashboard-metric-card > p:nth-child(2) {
    font-size: 23px !important;
    line-height: 28px !important;
  }

  body.dashboard-v2 #page-layout-editor form.grid,
  body.dashboard-v2 #quote-editor form.grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  body.dashboard-v2 .sticky.bottom-4 {
    bottom: 8px !important;
  }

  body.dashboard-v2 .affiliate-topbar__inner {
    min-height: 56px;
    gap: 10px;
    padding: 0 12px;
  }

  body.dashboard-v2 .affiliate-topbar__start {
    gap: 0;
  }

  body.dashboard-v2 .affiliate-brand__name {
    font-size: 14px;
  }

  body.dashboard-v2 .affiliate-brand {
    min-height: 44px;
  }

  body.dashboard-v2 .affiliate-brand__section {
    font-size: 9px;
  }

  body.dashboard-v2 .affiliate-tabs--desktop {
    display: none;
  }

  body.dashboard-v2 .affiliate-tabs--mobile {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px;
    border-top: 1px solid var(--v2-border);
    padding: 6px 10px;
    overflow: visible;
  }

  body.dashboard-v2 .affiliate-tab {
    min-height: 44px;
    padding: 7px 9px;
    font-size: 12px;
  }

  body.dashboard-v2 .affiliate-account {
    gap: 5px;
  }

  body.dashboard-v2 .affiliate-account__name,
  body.dashboard-v2 .affiliate-logout span:last-child {
    display: none;
  }

  body.dashboard-v2 .affiliate-avatar {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
  }

  body.dashboard-v2 .affiliate-icon-button,
  body.dashboard-v2 .affiliate-logout {
    width: 44px;
    min-height: 44px;
    padding: 0;
  }

  body.dashboard-v2 .affiliate-workspace {
    padding: 14px 14px 32px;
  }

  body.dashboard-v2 .affiliate-hero,
  body.dashboard-v2 .affiliate-hero__content {
    min-height: 150px;
  }

  body.dashboard-v2 .affiliate-hero__content {
    padding: 22px 20px;
  }

  body.dashboard-v2 .affiliate-hero h1 {
    font-size: 24px;
  }

  body.dashboard-v2 .affiliate-hero p {
    font-size: 13px;
  }

  body.dashboard-v2 .affiliate-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
  }

  body.dashboard-v2 .affiliate-metric-card {
    min-height: 116px;
    padding: 14px;
  }

  body.dashboard-v2 .affiliate-metric-card__heading {
    align-items: flex-start;
    font-size: 10px;
    line-height: 1.3;
  }

  body.dashboard-v2 .affiliate-metric-card__icon {
    width: 30px;
    height: 30px;
    flex-basis: 30px;
    font-size: 18px !important;
  }

  body.dashboard-v2 .affiliate-metric-card strong {
    margin-top: 15px;
    font-size: 21px;
  }

  body.dashboard-v2 .affiliate-stores {
    margin-top: 24px;
  }

  body.dashboard-v2 .affiliate-section-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  body.dashboard-v2 .affiliate-section-heading h2 {
    font-size: 20px;
  }

  body.dashboard-v2 .affiliate-store-card {
    padding: 16px;
  }

  body.dashboard-v2 .affiliate-store-card__header {
    align-items: flex-start;
  }

  body.dashboard-v2 .affiliate-store-card__identity h3 {
    font-size: 16px;
  }

  body.dashboard-v2 .affiliate-store-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px 0;
    padding: 16px 0;
  }

  body.dashboard-v2 .affiliate-store-stats > div {
    padding: 0 12px;
  }

  body.dashboard-v2 .affiliate-store-stats > div:nth-child(odd) {
    padding-left: 0;
    border-left: 0;
  }

  body.dashboard-v2 .affiliate-store-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
  }

  body.dashboard-v2 .affiliate-primary-action,
  body.dashboard-v2 .affiliate-secondary-action {
    width: 100%;
  }
}

@media (max-width: 420px) {
  body.dashboard-v2 .dashboard-topbar .dashboard-public-link {
    max-width: 110px;
    padding-inline: 10px !important;
  }

  body.dashboard-v2 .store-reseller-identity {
    display: none !important;
  }

  body.dashboard-v2 .dashboard-metrics {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.dashboard-v2 *,
  body.dashboard-v2 *::before,
  body.dashboard-v2 *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

@media print {
  body.dashboard-v2 .dashboard-topbar,
  body.dashboard-v2 .dashboard-sidebar {
    display: none !important;
  }

  body.dashboard-v2 :is(main, div):has(> .dashboard-sidebar) {
    padding: 0 !important;
    background: #fff !important;
  }
}
