/* Platform DS — tokens + components
   Source: Figma Platform-DS (EThNhzIdmHyiKDY1wiAKol)
   Icons: node 220:181 · COMPONENTS: node 220:183 */

:root,
.fd-theme {
  /* —— Primitives (Color Board) —— */
  --white: #FFFFFF;
  --gray-50: #F8F8FA;
  --gray-75: #EFEEF1;
  --gray-100: #E4E3E8;
  --gray-200: #DEDDE3;
  --gray-300: #BBB9C6;
  --gray-400: #A09DAF;
  --gray-500: #928FA3;
  --gray-600: #87849A;
  --gray-700: #6E6A85;
  --gray-900: #26252D;
  --gray-light: var(--gray-200);
  --gray-dark: var(--gray-500);

  --purple-50: #F0F2FB;
  --purple-100: #DDE0F5;
  --purple-200: #BCB7F0;
  --purple-300: #9B8EEC;
  --purple-400: #7A64E7;
  --purple-500: #593BE2;
  --purple-700: #4914D5;

  --green-100: #E6F4EC;
  --green-500: #68C170;
  --green-600: #12B76A;
  --green-700: #147D57;

  --amber-100: #FFF3E4;
  --amber-400: #FF9314;
  --amber-500: #D9822B;
  --amber-700: #B26B00;

  --red-100: #FCEBEB;
  --red-500: #CC3232;
  --red-600: #E33813;

  --blue-100: #EAF2FE;
  --blue-500: #2563EB;

  /* —— Semantic tokens (Semantic Tokens Board) —— */
  --fd-bg-page: var(--white);
  --fd-bg-subtle: var(--purple-50);
  --fd-bg-nav: var(--gray-900);
  --fd-bg-overlay: var(--gray-900);
  --fd-bg-disabled: var(--gray-75);
  --fd-bg-canvas: var(--gray-50);

  --fd-text-primary: var(--gray-900);
  --fd-text-secondary: var(--gray-700);
  --fd-text-muted: var(--gray-400);
  --fd-text-inverse: var(--white);
  --fd-text-link: var(--purple-500);
  --fd-text-error: var(--red-600);

  --fd-action-primary: var(--purple-500);
  --fd-action-primary-pressed: var(--purple-700);
  --fd-action-primary-subtle: var(--purple-50);
  --fd-action-secondary-border: var(--purple-300);

  --fd-border-default: var(--gray-100);
  --fd-border-input: var(--gray-200);
  --fd-border-focus: var(--purple-700);

  --fd-icon-default: var(--gray-400);
  --fd-icon-hover: var(--gray-900);

  --fd-status-success: var(--green-500);
  --fd-status-success-subtle: var(--green-100);
  --fd-status-success-ink: var(--green-700);
  --fd-status-success-fill: var(--green-600);
  --fd-status-error: var(--red-500);
  --fd-status-error-subtle: var(--red-100);
  --fd-status-warning: var(--amber-700);
  --fd-status-warning-subtle: var(--amber-100);
  --fd-status-warning-fill: var(--amber-500);
  --fd-status-info-subtle: var(--blue-100);
  --fd-status-info-ink: var(--blue-500);
  --fd-red-300: #DB2424;

  /* Elevation / radius */
  --fd-shadow-card: 0 1px 6px rgba(34, 40, 49, 0.08);
  --fd-shadow-card-hover: 0 4px 14px rgba(34, 40, 49, 0.1);
  --fd-shadow-popover: 0 2px 45px rgba(34, 40, 49, 0.2);
  --fd-shadow-selector-hover: 0 0 0 3px rgba(130, 156, 246, 0.25);
  --fd-r-control: 6px;
  --fd-r-container: 24px;
  --fd-r-pill: 999px;
  --fd-r-label: 999px;
  --fd-r-badge: 6px;
  --fd-r-snack: 12px;

  /* Type */
  --fd-font: "Inter", "Open Sans", system-ui, -apple-system, sans-serif;
  --fd-font-weight-label: 500; /* Label / Label Small — Medium */
  --motion-micro: 120ms;
  --ease-out: cubic-bezier(.2, .8, .2, 1);
  --fd-hover-dur: 260ms;
  --fd-hover-ease: cubic-bezier(.4, 0, .2, 1);

  /* Figma-parity aliases */
  --color-bg-page: var(--fd-bg-page);
  --color-bg-subtle: var(--fd-bg-subtle);
  --color-bg-nav: var(--fd-bg-nav);
  --color-bg-overlay: var(--fd-bg-overlay);
  --color-bg-disabled: var(--fd-bg-disabled);
  --color-bg-canvas: var(--fd-bg-canvas);
  --color-text-primary: var(--fd-text-primary);
  --color-text-secondary: var(--fd-text-secondary);
  --color-text-muted: var(--fd-text-muted);
  --color-text-inverse: var(--fd-text-inverse);
  --color-text-link: var(--fd-text-link);
  --color-text-error: var(--fd-text-error);
  --color-action-primary: var(--fd-action-primary);
  --color-action-primary-pressed: var(--fd-action-primary-pressed);
  --color-action-primary-subtle: var(--fd-action-primary-subtle);
  --color-action-secondary-border: var(--fd-action-secondary-border);
  --color-border-default: var(--fd-border-default);
  --color-border-input: var(--fd-border-input);
  --color-border-focus: var(--fd-border-focus);
  --color-icon-default: var(--fd-icon-default);
  --color-icon-hover: var(--fd-icon-hover);
  --color-status-success: var(--fd-status-success);
  --color-status-error: var(--fd-status-error);
  --color-status-error-subtle: var(--fd-status-error-subtle);
  --color-status-warning: var(--fd-status-warning);
  --color\/status\/error-subtle: var(--fd-status-error-subtle);
  --color\/status\/warning-subtle: var(--fd-status-warning-subtle);

  --font: var(--fd-font);
  --brand: var(--fd-action-primary);
  --brand-hover: var(--fd-action-primary-pressed);
  --brand-weak: var(--fd-action-primary-subtle);
  --ink-900: var(--fd-text-primary);
  --ink-500: var(--fd-text-secondary);
  --ink-400: var(--fd-text-secondary);
  --ink-300: var(--fd-text-muted);
  --line: var(--fd-border-default);
  --line-weak: var(--fd-border-input);
  --surface: var(--fd-bg-page);
  --sunken: var(--fd-bg-canvas);
  --e1: var(--fd-shadow-card);
  --r-md: var(--fd-r-control);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-font-smoothing: antialiased; }
body {
  margin: 0;
  font-family: var(--fd-font);
  color: var(--fd-text-secondary);
  background: var(--fd-bg-canvas);
}
button { font: inherit; }
img { display: block; max-width: 100%; }

/* ---- Typography ---- */
.fd-ty-h2 { font-size: 24px; font-weight: 600; line-height: 40px; color: var(--fd-text-primary); margin: 0; }
.fd-ty-h3 { font-size: 20px; font-weight: 700; line-height: 28px; color: var(--fd-text-primary); margin: 0; }
.fd-ty-h4 { font-size: 17px; font-weight: 700; line-height: 24px; color: var(--fd-text-primary); margin: 0; }
.fd-ty-h6 { font-size: 15px; font-weight: 600; line-height: 20px; color: var(--fd-text-primary); margin: 0; }
.fd-ty-body { font-size: 14px; font-weight: 400; line-height: 20px; }
.fd-ty-body-lg { font-size: 15px; font-weight: 400; line-height: 20px; }
.fd-ty-body-sm { font-size: 13px; font-weight: 400; line-height: 18px; }
.fd-ty-link { font-size: 14px; font-weight: 600; line-height: 18px; color: var(--fd-text-link); }
.fd-ty-tiny { font-size: 11px; font-weight: 600; line-height: 18px; text-transform: uppercase; }
.fd-ty-label { font-size: 14px; font-weight: var(--fd-font-weight-label); line-height: 20px; }
.fd-ty-table-header-sm { font-size: 13px; font-weight: 600; line-height: 16px; color: var(--fd-text-primary); margin: 0; }

/* ---- Buttons ---- */
.fd-btn {
  appearance: none;
  -webkit-appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-family: var(--fd-font);
  font-weight: 600;
  border-radius: var(--fd-r-control);
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: none;
  transition:
    background var(--fd-hover-dur, 260ms) var(--fd-hover-ease, cubic-bezier(.4, 0, .2, 1)),
    color var(--fd-hover-dur, 260ms) var(--fd-hover-ease, cubic-bezier(.4, 0, .2, 1)),
    border-color var(--fd-hover-dur, 260ms) var(--fd-hover-ease, cubic-bezier(.4, 0, .2, 1)),
    box-shadow var(--fd-hover-dur, 260ms) var(--fd-hover-ease, cubic-bezier(.4, 0, .2, 1));
}
.fd-btn:hover {
  box-shadow: var(--fd-shadow-card);
}
.fd-btn:focus-visible {
  outline: 2px solid var(--fd-action-primary);
  outline-offset: 2px;
}
.fd-btn svg { flex: none; }
.fd-btn-lg { height: 40px; padding: 0 24px; font-size: 16px; line-height: 16px; }
.fd-btn-md { height: 36px; padding: 0 12px; font-size: 14px; line-height: 20px; font-weight: 500; }
.fd-btn-sm { height: 28px; padding: 0 12px; font-size: 12px; line-height: 16px; letter-spacing: 0; }
.fd-btn-lg.fd-btn-icon { padding-left: 8px; padding-right: 16px; gap: 4px; }
.fd-btn-md.fd-btn-icon { padding: 8px; gap: 4px; }
.fd-btn-sm.fd-btn-icon { height: 32px; padding-left: 8px; padding-right: 12px; }
/* Medium Icon/Plus is a 20px frame with a 12px glyph (Figma 394:542) */
.fd-btn-md.fd-btn-icon svg,
.fd-btn-md.fd-btn-icon .bp-icon,
.fd-btn-md.fd-btn-icon .fd-icon {
  width: 20px;
  height: 20px;
  padding: 4px;
  box-sizing: border-box;
}

.fd-btn-primary { background: var(--fd-action-primary); color: var(--fd-text-inverse); }
.fd-btn-primary:hover { background: var(--fd-action-primary-pressed); }
.fd-btn-secondary {
  background: var(--fd-bg-page);
  color: var(--fd-text-link);
  border-color: var(--fd-action-secondary-border);
}
.fd-btn-secondary:hover {
  background: var(--fd-action-primary-subtle);
  color: var(--fd-action-primary);
  border-color: var(--fd-action-primary);
}
.fd-btn-inverted {
  background: var(--fd-action-primary-subtle);
  color: var(--fd-action-primary-pressed);
}
.fd-btn-text {
  background: transparent;
  color: var(--fd-text-link);
  border-color: transparent;
}
.fd-btn-text:hover {
  background: var(--fd-action-primary-subtle);
  color: var(--fd-action-primary-pressed);
}
.fd-btn-danger {
  background: var(--fd-status-error-subtle);
  color: var(--fd-status-error);
}
.fd-btn-danger:hover { filter: brightness(.97); }
.fd-btn-icon-only {
  width: 40px; height: 40px; padding: 0;
  background: var(--fd-action-primary-subtle);
  color: var(--fd-action-primary);
  border-radius: 10px;
}
.fd-btn-icon-only.fd-btn-md { width: 36px; height: 36px; border-radius: 9px; }
.fd-btn-icon-only.fd-btn-sm { width: 32px; height: 32px; border-radius: 8px; }
.fd-btn-icon-only svg { width: 18px; height: 18px; }
.fd-btn-icon-only.fd-btn-sm svg { width: 16px; height: 16px; }
@media (prefers-reduced-motion: reduce) {
  .fd-btn { transition: none; }
}

/* ---- Tabs (underline) ---- */
.fd-tabs {
  display: flex;
  align-items: flex-end;
  gap: 24px;
  border: 0;
  background: transparent;
}
.fd-tabs .fd-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding-top: 10px;
  min-width: 100px;
  cursor: pointer;
  color: var(--fd-text-secondary);
  font-size: 14px;
  font-weight: 400;
  line-height: 20px;
  user-select: none;
}
.fd-tabs .fd-tab::after {
  content: "";
  display: block;
  height: 2px;
  width: 100%;
  background: transparent;
}
.fd-tabs .fd-tab.on {
  color: var(--fd-text-link);
  font-weight: 600;
  line-height: 18px;
}
.fd-tabs .fd-tab.on::after {
  width: 50px;
  background: var(--fd-action-primary);
}

/* ---- Inputs ---- */
.fd-input {
  display: block;
  width: 230px;
  height: 40px;
  min-height: 40px;
  padding: 0 12px;
  border-radius: var(--fd-r-control);
  border: 1px solid var(--fd-border-input);
  background: var(--fd-bg-page);
  font-family: var(--fd-font);
  font-size: 14px;
  font-weight: 400;
  line-height: 20px;
  color: var(--fd-text-primary);
  box-sizing: border-box;
}
.fd-input::placeholder { color: var(--fd-text-muted); font-weight: 400; }
.fd-input:focus,
.fd-input.is-active {
  outline: 0;
  border: 2px solid var(--fd-border-focus);
  padding: 0 11px;
}
.fd-input:disabled,
.fd-input.is-disabled {
  background: var(--fd-bg-disabled);
  border-color: transparent;
  color: var(--fd-text-muted);
}
.fd-input.is-error {
  border-color: var(--fd-status-error);
  color: var(--fd-status-error);
}
.fd-input.is-error::placeholder { color: var(--fd-status-error); }
.fd-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 280px;
}
.fd-field-label-row {
  display: flex;
  align-items: center;
  gap: 6px;
}
.fd-field-label {
  font-size: 14px;
  line-height: 20px;
  color: var(--fd-text-primary);
}
.fd-field-optional {
  font-size: 13px;
  line-height: 18px;
  color: var(--fd-text-muted);
}
.fd-field .fd-input { width: 100%; }
.fd-field-help {
  margin: 0;
  font-size: 13px;
  line-height: 18px;
  color: var(--fd-text-muted);
}
.fd-field-error {
  margin: 0;
  font-size: 12px;
  line-height: 16px;
  color: var(--fd-status-error);
}
.fd-field-row {
  display: inline-flex;
  align-items: center;
  gap: 24px;
}
.fd-field-row .fd-field-label {
  width: 100px;
  text-align: right;
  font-size: 14px;
  color: var(--fd-text-secondary);
}
.fd-textarea {
  display: block;
  width: 320px;
  height: 250px;
  padding: 10px 12px;
  border-radius: var(--fd-r-control);
  border: 1px solid var(--fd-border-input);
  background: var(--fd-bg-page);
  font-family: var(--fd-font);
  font-size: 14px;
  font-weight: 400;
  line-height: 20px;
  color: var(--fd-text-primary);
  resize: vertical;
  box-sizing: border-box;
}
.fd-textarea::placeholder { color: var(--fd-text-muted); }
.fd-textarea:focus,
.fd-textarea.is-active {
  outline: 0;
  border: 2px solid var(--fd-border-focus);
  padding: 9px 11px;
}
.fd-textarea.is-error {
  border-color: var(--fd-status-error);
  color: var(--fd-status-error);
}
.fd-textarea:disabled,
.fd-textarea.is-disabled {
  background: var(--fd-bg-disabled);
  border-color: transparent;
  color: var(--fd-text-muted);
}
.fd-select.is-hover {
  background: var(--fd-bg-subtle);
  border-color: var(--fd-action-primary);
  color: var(--fd-text-link);
}
.fd-select.is-hover .select-val { color: var(--fd-text-link); }
.fd-select.is-hover svg { color: var(--fd-text-link); }
.fd-select.is-active {
  border: 2px solid var(--fd-border-focus);
  color: var(--fd-text-link);
}
.fd-select.is-active .select-val { color: var(--fd-text-link); }
.fd-select.is-active svg { color: var(--fd-text-link); }
.fd-select.has-value .select-val { color: var(--fd-text-primary); }

/* ---- Select / dropdown field ---- */
.fd-selectbox { position: relative; display: inline-block; }
.fd-select {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 230px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--fd-border-input);
  border-radius: var(--fd-r-control);
  background: var(--fd-bg-page);
  color: var(--fd-text-secondary);
  font-size: 14px;
  cursor: pointer;
}
.fd-select svg { width: 12px; height: 12px; flex: none; transition: transform var(--motion-micro) var(--ease-out); }
.fd-selectbox.open .fd-select {
  border-color: var(--fd-action-primary);
  box-shadow: 0 0 0 3px var(--fd-action-primary-subtle);
}
.fd-selectbox.open .fd-select svg { transform: rotate(180deg); }
.fd-select-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 100%;
  background: var(--fd-bg-page);
  border: 1px solid var(--fd-border-default);
  border-radius: 8px;
  box-shadow: var(--fd-shadow-card);
  padding: 6px;
  z-index: 20;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity var(--motion-micro) var(--ease-out), transform var(--motion-micro) var(--ease-out), visibility 0s linear var(--motion-micro);
}
.fd-selectbox.open .fd-select-menu {
  opacity: 1; visibility: visible; transform: none;
  transition: opacity var(--motion-micro) var(--ease-out), transform var(--motion-micro) var(--ease-out), visibility 0s;
}
.fd-select-opt {
  padding: 8px 10px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  color: var(--fd-text-primary);
}
.fd-select-opt:hover,
.fd-select-opt.sel {
  background: var(--fd-action-primary-subtle);
  color: var(--fd-text-link);
}

/* ---- Search ---- */
.fd-search {
  display: inline-flex;
  align-items: center;
  flex-direction: row-reverse;
  justify-content: flex-end;
  gap: 12px;
  width: 160px;
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--fd-border-input);
  border-radius: 8px;
  background: var(--fd-bg-page);
  box-sizing: border-box;
}
.fd-search svg { width: 16px; height: 16px; color: var(--fd-text-muted); flex: none; }
.fd-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font: inherit;
  font-size: 14px;
  font-weight: 400;
  color: var(--fd-text-primary);
}
.fd-search input::placeholder { color: var(--fd-text-muted); }
.fd-search.is-active,
.fd-search:focus-within {
  border-color: var(--fd-action-primary);
}
.fd-search-md {
  width: 160px;
  height: 40px;
  padding: 0 12px;
}
.fd-search-lg {
  width: 560px;
  max-width: 100%;
  height: 64px;
  padding: 0 16px;
  border-radius: 16px;
}
.fd-search-lg svg { width: 20px; height: 20px; color: var(--fd-text-muted); }
.fd-search-lg input { font-size: 18px; font-weight: 500; line-height: 24px; }
.fd-search-lg.is-active,
.fd-search-lg:focus-within { border-color: var(--fd-border-focus); }
.fd-search input::-webkit-search-decoration,
.fd-search input::-webkit-search-cancel-button,
.fd-search input::-webkit-search-results-button,
.fd-search input::-webkit-search-results-decoration {
  -webkit-appearance: none;
}


/* ---- Checkbox / Radio ---- */
.fd-check,
.fd-radio {
  appearance: none;
  width: 20px;
  height: 20px;
  margin: 0;
  cursor: pointer;
  background: var(--fd-bg-page);
  border: 1.5px solid var(--gray-300);
  display: inline-grid;
  place-items: center;
  flex: none;
}
.fd-check { border-radius: 4px; }
.fd-radio { border-radius: 100px; }
.fd-check:checked {
  background: var(--fd-action-primary);
  border-color: var(--fd-action-primary);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 8'%3E%3Cpath d='M1 4l2.5 2.5L9 1' fill='none' stroke='%23fff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px 8px;
}
.fd-radio:checked {
  border: 2px solid var(--fd-action-primary);
  background-image: radial-gradient(circle, var(--fd-action-primary) 0 4px, transparent 5px);
}

/* ---- Switch ---- */
.fd-switch {
  position: relative;
  width: 42px;
  height: 24px;
  border-radius: 12px;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: #DEDDE3;
  transition: background .15s;
  flex: none;
}
.fd-switch::after {
  content: "";
  position: absolute;
  top: 4px; left: 3px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: #9492A1;
  transition: transform .15s, background .15s, box-shadow .15s;
}
.fd-switch[aria-checked="true"] { background: var(--purple-100); }
.fd-switch[aria-checked="true"]::after {
  transform: translateX(20px);
  background: var(--fd-action-primary);
}
.fd-switch:hover::after { box-shadow: var(--fd-shadow-selector-hover); }
/* Yes / No pill toggle (forms) — solid labeled control matching property forms */
.fd-switch-yn {
  width: auto;
  min-width: 56px;
  height: 32px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--fd-font);
  font-size: 13px;
  font-weight: var(--fd-font-weight-label);
  line-height: 18px;
  color: var(--fd-text-primary);
  background: var(--purple-100);
  box-shadow: none;
}
.fd-switch-yn:focus,
.fd-switch-yn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--fd-action-primary-subtle);
}
.fd-switch-yn::after {
  display: none;
}
.fd-switch-yn[aria-checked="true"] {
  color: var(--fd-text-primary);
  background: var(--purple-100);
}
.fd-switch-yn[aria-checked="true"]::after {
  display: none;
}
.fd-switch-yn-label {
  position: relative;
  z-index: 1;
  pointer-events: none;
  text-align: center;
}
.fd-switch-labeled {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  line-height: 18px;
  color: var(--fd-text-secondary);
  text-transform: capitalize;
}

/* ---- Badges ---- */
.fd-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  height: 24px;
  padding: 4px 6px;
  border-radius: var(--fd-r-badge);
  font-size: 14px;
  font-weight: var(--fd-font-weight-label);
  line-height: 16px;
  color: var(--fd-text-inverse);
  background: var(--fd-action-primary);
}
.fd-badge-red { background: var(--fd-status-error); }
.fd-badge-gray {
  background: var(--fd-action-primary-subtle);
  color: var(--fd-text-link);
  min-width: 24px;
}
.fd-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 14px;
  border-radius: 8px;
  background: var(--fd-status-warning-subtle);
  color: var(--amber-700);
  font-size: 13px;
  line-height: 18px;
}
.fd-status-badge strong { font-size: 14px; font-weight: 600; line-height: 16px; }

/* ---- Labels / tags ---- */
.fd-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 32px;
  padding: 8px 12px;
  border-radius: var(--fd-r-label);
  font-size: 13px;
  font-weight: var(--fd-font-weight-label);
  line-height: 20px;
  white-space: nowrap;
  box-sizing: border-box;
}
.fd-label-neutral-soft { background: var(--gray-75); color: var(--gray-700); }
.fd-label-neutral-solid { background: var(--gray-700); color: #fff; }
.fd-label-primary-soft { background: var(--purple-50); color: var(--purple-700); }
.fd-label-primary-solid { background: var(--purple-500); color: #fff; }
.fd-label-success-soft { background: var(--green-100); color: var(--green-700); }
.fd-label-success-solid { background: var(--green-600); color: #fff; }
.fd-label-warning-soft { background: var(--amber-100); color: var(--amber-700); }
.fd-label-warning-solid { background: var(--amber-500); color: #fff; }
.fd-label-error-soft { background: var(--red-100); color: var(--red-500); }
.fd-label-error-solid { background: var(--red-500); color: #fff; }
.fd-label.has-icon { gap: 4px; padding-left: 8px; padding-right: 12px; }
.fd-label svg { width: 16px; height: 16px; flex: none; }
.fd-label svg path { fill: currentColor; }

/* ---- Chips / Info ---- */
.fd-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px 6px 12px;
  border-radius: var(--fd-r-pill);
  border: 1px solid var(--fd-border-input);
  background: var(--fd-bg-page);
  color: var(--fd-text-secondary);
  font-size: 13px;
  line-height: normal;
}
.fd-chip button {
  display: grid; place-items: center;
  width: 10px; height: 10px; padding: 0; border: 0;
  background: transparent; color: inherit; cursor: pointer;
}
.fd-chip button svg { width: 10px; height: 10px; }
.fd-chip.is-active {
  background: var(--fd-action-primary-subtle);
  border-color: var(--fd-action-primary);
  color: var(--fd-text-link);
  font-weight: 600;
}
.fd-info {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 12px;
  border-radius: var(--fd-r-pill);
  background: var(--fd-bg-disabled);
  font-size: 12px;
  line-height: 18px;
  color: var(--fd-text-secondary);
  text-transform: capitalize;
}

/* ---- Alerts / Status inline ---- */
.fd-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: var(--fd-r-pill);
  font-size: 12px;
  font-weight: 600;
  line-height: 18px;
  white-space: nowrap;
}
.fd-status.success {
  background: var(--fd-status-success-subtle);
  color: var(--fd-status-success-ink);
}
.fd-status.error {
  background: var(--fd-status-error-subtle);
  color: var(--fd-status-error);
}
.fd-status-ic {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex: none;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
}
.fd-status-ic.success { background: var(--fd-status-success); }
.fd-status-ic.error { background: var(--fd-status-error); }

.fd-alert {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 568px;
  padding: 12px 16px;
  border-radius: 4px;
  border: 1px solid;
  background: var(--fd-bg-page);
  font-size: 14px;
  color: var(--fd-text-primary);
}
.fd-alert.success { border-color: var(--fd-status-success); }
.fd-alert.error { border-color: var(--fd-status-error); }
.fd-alert .fd-alert-x {
  margin-left: auto;
  width: 10px; height: 10px; padding: 0; border: 0;
  background: transparent; color: var(--fd-text-muted); cursor: pointer;
}

/* ---- Banner ---- */
.fd-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 993px;
  padding: 12px 16px;
  border-radius: 4px;
  background: var(--fd-action-primary-subtle);
  color: var(--fd-action-primary-pressed);
  font-size: 14px;
  font-weight: 600;
}

/* ---- Snackbar ---- */
.fd-snackbar {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  max-width: 460px;
  min-height: 56px;
  padding: 16px 20px;
  border-radius: var(--fd-r-snack);
  font-size: 16px;
  font-weight: 600;
}
.fd-snackbar .fd-snack-x {
  margin-left: auto;
  position: relative;
  isolation: isolate;
  width: 18px;
  height: 18px;
  min-width: 18px;
  min-height: 18px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  cursor: pointer;
  color: var(--fd-icon-default, inherit);
  display: grid;
  place-items: center;
  overflow: visible;
  flex: none;
  transition: color .16s ease;
}
.fd-snackbar .fd-snack-x::before {
  content: "";
  position: absolute;
  z-index: 0;
  left: 50%;
  top: 50%;
  width: 40px;
  height: 40px;
  margin: -20px 0 0 -20px;
  border-radius: 8px;
  background: var(--fd-bg-subtle, var(--fd-action-primary-subtle));
  opacity: 0;
  transform: scale(0.92);
  pointer-events: none;
  transition: opacity .16s ease, transform .16s ease;
}
.fd-snackbar .fd-snack-x:hover,
.fd-snackbar .fd-snack-x:focus-visible {
  outline: none;
  color: var(--fd-action-primary);
}
.fd-snackbar .fd-snack-x:hover::before,
.fd-snackbar .fd-snack-x:focus-visible::before {
  opacity: 1;
  transform: scale(1);
}
.fd-snackbar .fd-snack-x:focus-visible::before {
  outline: 2px solid var(--fd-action-primary);
  outline-offset: 1px;
}
.fd-snackbar .fd-snack-x img,
.fd-snackbar .fd-snack-x svg,
.fd-snackbar .fd-snack-x .bp-icon {
  position: relative;
  z-index: 1;
  width: 18px;
  height: 18px;
  max-width: 18px;
  max-height: 18px;
  color: inherit;
  fill: currentColor;
  overflow: hidden;
}
.fd-snackbar .fd-snack-x:hover img,
.fd-snackbar .fd-snack-x:focus-visible img {
  /* Recolor gray asset to action primary (#593BE2); prefer currentColor SVG */
  filter: brightness(0) saturate(100%) invert(27%) sepia(72%) saturate(2878%) hue-rotate(239deg) brightness(89%) contrast(97%);
}
@media (prefers-reduced-motion: reduce) {
  .fd-snackbar .fd-snack-x,
  .fd-snackbar .fd-snack-x::before { transition: none; }
}
.fd-snackbar.info { background: var(--blue-100); color: var(--blue-500); }
.fd-snackbar.warning { background: var(--amber-100); color: var(--amber-700); }
.fd-snackbar.success { background: var(--green-100); color: var(--green-700); }
.fd-snackbar.error { background: var(--red-100); color: var(--red-500); }
.fd-snackbar .fd-snack-ic { width: 24px; height: 24px; flex: none; display: grid; place-items: center; }
.fd-snackbar.is-stack {
  flex-direction: row;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 8px;
  width: 388px;
  max-width: calc(100vw - 48px);
  height: auto;
  min-height: 0;
  padding: 16px 12px 16px 8px;
  border: 1px solid var(--fd-border-input, var(--gray-200));
  border-radius: 12px;
  background: var(--fd-bg-page, var(--white));
  color: var(--fd-icon-default, var(--gray-400));
  box-shadow: var(--fd-shadow-popover);
  font-size: inherit;
  font-weight: inherit;
}
.fd-snackbar.is-stack .fd-snack-row {
  display: flex;
  align-items: flex-start;
  flex: none;
  gap: 8px;
  width: 100%;
  min-width: 0;
}
.fd-snackbar.is-stack .fd-snack-ic {
  width: 24px;
  height: 24px;
  padding: 4px;
  box-sizing: border-box;
}
.fd-snackbar.is-stack .fd-snack-ic img,
.fd-snackbar.is-stack .fd-snack-ic svg {
  width: 16px;
  height: 16px;
  display: block;
}
.fd-snackbar.is-stack .fd-snack-text {
  flex: 1 0 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.fd-snackbar.is-stack .fd-snack-title {
  margin: 0;
  font-size: 14px;
  font-weight: 500;
  line-height: 20px;
  color: var(--fd-text-primary, var(--gray-900));
}
.fd-snackbar.is-stack .fd-snack-body {
  margin: 0;
  font-size: 13px;
  font-weight: 400;
  line-height: 18px;
  color: var(--fd-text-secondary, var(--gray-700));
}
.fd-snackbar.is-stack .fd-snack-x {
  flex: none;
  align-self: flex-start;
  margin-left: 0;
  width: 18px;
  height: 18px;
  min-width: 18px;
  min-height: 18px;
  opacity: 1;
}
.fd-snackbar.is-stack .fd-snack-x img,
.fd-snackbar.is-stack .fd-snack-x svg,
.fd-snackbar.is-stack .fd-snack-x .bp-icon {
  width: 18px;
  height: 18px;
  max-width: 18px;
  max-height: 18px;
  display: block;
}

/* Dark theme — Figma Toast Theme=Dark (812:260), 388×90 */
.fd-snackbar.is-stack.dark {
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  gap: 0;
  width: 388px;
  min-height: 90px;
  padding: 16px 12px 16px 8px;
  border: 0;
  border-radius: 12px;
  background: var(--gray-900);
  color: var(--white);
  box-shadow: var(--fd-shadow-popover);
}
.fd-snackbar.is-stack.dark .fd-snack-row {
  width: 100%;
  gap: 8px;
  align-items: flex-start;
}
.fd-snackbar.is-stack.dark .fd-snack-ic {
  width: 24px;
  height: 24px;
  padding: 0;
}
.fd-snackbar.is-stack.dark .fd-snack-ic img {
  width: 24px;
  height: 24px;
  display: block;
}
.fd-snackbar.is-stack.dark .fd-snack-text {
  flex: 1 0 0;
  gap: 2px;
  justify-content: center;
}
.fd-snackbar.is-stack.dark .fd-snack-title {
  color: var(--white);
  font-size: 14px;
  font-weight: 500;
  line-height: 20px;
  letter-spacing: 0;
}
.fd-snackbar.is-stack.dark .fd-snack-body {
  color: var(--gray-300);
  font-size: 13px;
  font-weight: 400;
  line-height: 18px;
  letter-spacing: 0;
}
.fd-snackbar.is-stack.dark .fd-snack-x {
  width: 18px;
  height: 18px;
  color: var(--gray-400);
}
.fd-snackbar.is-stack.dark .fd-snack-x img {
  width: 18px;
  height: 18px;
}
.fd-snackbar.is-stack.dark .fd-snack-x::before {
  background: rgba(255, 255, 255, 0.08);
}
.fd-snackbar.is-stack.dark .fd-snack-x:hover,
.fd-snackbar.is-stack.dark .fd-snack-x:focus-visible {
  color: var(--white);
}
.fd-snackbar.is-stack.dark .fd-snack-x:hover img,
.fd-snackbar.is-stack.dark .fd-snack-x:focus-visible img {
  filter: brightness(0) invert(1);
}

/* ---- Toast (legacy alias → dark snackbar) ---- */
.fd-toast {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  width: 100%;
  max-width: 388px;
  padding: 16px 12px 16px 8px;
  border-radius: var(--fd-r-snack);
  background: var(--gray-900);
  color: var(--white);
  box-shadow: var(--fd-shadow-popover);
  font-size: 14px;
  font-weight: 500;
  line-height: 20px;
}
.fd-toast .fd-toast-x {
  margin-left: auto;
  width: 18px;
  height: 18px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--gray-400);
  cursor: pointer;
}

/* ---- Steps ---- */
.fd-steps { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.fd-step {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 400;
  line-height: 20px;
  color: var(--fd-text-primary);
}
.fd-step.current { font-weight: 600; color: var(--fd-text-link); }
.fd-step.upcoming { font-size: 14px; font-weight: 500; color: var(--fd-text-secondary); }
.fd-step-ic {
  width: 24px;
  height: 24px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex: none;
  box-sizing: border-box;
  background: var(--fd-action-primary-subtle);
  color: transparent;
  font-size: 0;
  overflow: hidden;
}
.fd-step-ic > * { display: none; }
.fd-step-ic::after {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--fd-action-primary);
}
.fd-step.current .fd-step-ic,
.fd-step-v.current .fd-step-ic,
.fd-step-h.current .fd-step-ic {
  background: var(--fd-bg-page);
  border: 2px solid var(--purple-100);
}
.fd-step.upcoming .fd-step-ic,
.fd-step-v.upcoming .fd-step-ic,
.fd-step-h.upcoming .fd-step-ic {
  background: var(--fd-bg-disabled);
  border: 0;
}
.fd-step.upcoming .fd-step-ic::after,
.fd-step-v.upcoming .fd-step-ic::after,
.fd-step-h.upcoming .fd-step-ic::after {
  background: var(--gray-300);
}

.fd-stepper-v {
  display: flex;
  flex-direction: column;
  width: 200px;
}
.fd-step-v {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  min-height: 72px;
}
.fd-step-v-ind {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  align-self: stretch;
}
.fd-step-v-line {
  width: 1px;
  flex: 1;
  min-height: 40px;
  background: var(--fd-border-input);
  border-radius: 1px;
}
.fd-step-v.complete .fd-step-v-line,
.fd-step-v.current .fd-step-v-line {
  background: var(--fd-action-primary);
}
.fd-step-v-body {
  padding-top: 4px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.fd-step-v-label {
  margin: 0;
  font-size: 15px;
  font-weight: 400;
  line-height: 20px;
  color: var(--fd-text-primary);
}
.fd-step-v.current .fd-step-v-label {
  font-size: 15px;
  font-weight: 600;
  color: var(--fd-text-link);
}
.fd-step-v.upcoming .fd-step-v-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--fd-text-secondary);
}
.fd-step-v-desc {
  margin: 0;
  font-size: 13px;
  line-height: 18px;
  color: var(--fd-text-muted);
}

.fd-stepper-h {
  display: flex;
  align-items: flex-start;
  width: 100%;
  gap: 0;
}
.fd-step-h {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.fd-step-h-ind {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}
.fd-step-h-line {
  flex: 1;
  height: 2px;
  background: var(--fd-border-input);
  border-radius: 1px;
}
.fd-step-h.complete .fd-step-h-line,
.fd-step-h.current .fd-step-h-line {
  background: var(--fd-action-primary);
}
.fd-step-h:last-child .fd-step-h-line { display: none; }
.fd-step-h-label {
  margin: 0;
  font-size: 15px;
  font-weight: 400;
  line-height: 20px;
  color: var(--fd-text-primary);
}
.fd-step-h.current .fd-step-h-label {
  font-size: 15px;
  font-weight: 600;
  color: var(--fd-text-link);
}
.fd-step-h.upcoming .fd-step-h-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--fd-text-secondary);
}


/* ---- Breadcrumbs ---- */
.fd-crumbs {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  line-height: 18px;
  font-weight: 400;
  text-transform: capitalize;
}
.fd-crumbs a { color: var(--fd-text-muted); text-decoration: none; font-weight: 400; }
.fd-crumbs a:hover { color: var(--fd-text-link); }
.fd-crumbs .current { color: var(--fd-text-primary); }
.fd-crumbs .sep { color: var(--fd-text-secondary); font-size: 12px; }
.fd-crumbs-dd-row {
  display: inline-flex;
  align-items: center;
  gap: 24px;
}
.fd-crumbs-dd {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  height: auto;
  padding: 4px 8px;
  border: 0;
  border-radius: 6px;
  background: var(--gray-75);
  color: var(--fd-text-primary);
  font-size: 13px;
  line-height: 18px;
  font-weight: 400;
  cursor: pointer;
  font-family: inherit;
}
.fd-crumbs-dd.is-current {
  padding: 6px 8px;
  font-weight: 500;
  line-height: 20px;
  cursor: default;
}
.fd-crumbs-dd svg { width: 12px; height: 7px; color: var(--fd-text-primary); }
.fd-crumbs-dd-row .sep { color: var(--fd-text-secondary); font-size: 12px; }

/* ---- Profile ---- */
.fd-profile { display: inline-flex; align-items: center; gap: 10px; }
.fd-avatar {
  width: 32px; height: 32px; border-radius: 16px;
  background: var(--fd-action-primary-subtle);
  color: var(--fd-text-link);
  display: grid; place-items: center;
  font-size: 12px; font-weight: 600; flex: none;
}
.fd-profile-name { font-size: 14px; color: var(--fd-text-secondary); }

/* ---- Table ---- */
.fd-table-wrap {
  border: 1px solid var(--fd-border-default);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}
table.fd-tbl {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}
table.fd-tbl thead th {
  height: 40px;
  padding: 0 16px;
  text-align: left;
  background: var(--fd-bg-subtle);
  color: var(--fd-text-primary);
  border-bottom: 1px solid var(--fd-border-default);
  font-size: 13px;
  font-weight: 600;
  line-height: 16px;
}
table.fd-tbl td {
  padding: 8px 12px;
  border-bottom: 1px solid var(--fd-border-input);
  font-size: 14px;
  color: var(--fd-text-primary);
}
table.fd-tbl tr:last-child td { border-bottom: 0; }

/* ---- Pagination ---- */
.fd-pagination {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px;
}
.fd-page {
  width: 32px; height: 32px; border-radius: 999px;
  display: grid; place-items: center;
  font-size: 14px; font-weight: 600;
  color: #87849A; cursor: pointer; user-select: none;
}
.fd-page.on { background: var(--fd-bg-subtle); color: var(--fd-action-primary); }
.fd-page-nav {
  width: 24px; height: 24px; color: var(--fd-action-primary);
  display: grid; place-items: center;
}
.fd-page-nav svg { width: 16px; height: 16px; }

/* ---- Cards ---- */
.fd-card {
  width: 100%;
  max-width: 348px;
  padding: 16px;
  border-radius: 12px;
  border: 1px solid var(--fd-border-input);
  background: #fff;
}
.fd-card.is-selected {
  border-color: var(--fd-action-primary);
  padding: 16px 20px;
}
.fd-card-row {
  display: flex;
  align-items: center;
  gap: 24px;
}
.fd-card-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.fd-card-title {
  font-size: 15px; font-weight: 600; line-height: 20px;
  color: var(--fd-text-primary); margin: 0;
}
.fd-card-id {
  margin: 0;
  font-size: 12px;
  line-height: 16px;
  color: var(--fd-text-secondary);
}
.fd-card-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.fd-card-meta-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  line-height: 16px;
  color: var(--fd-text-secondary);
}
.fd-card-meta-row svg {
  width: 16px; height: 16px; flex: none; color: var(--fd-icon-default);
}
.fd-card-meta-row svg path { fill: currentColor; }
.fd-card-actions {
  display: flex;
  align-items: center;
  gap: 24px;
  color: var(--fd-action-primary);
}
.fd-card-actions button {
  border: 0; background: transparent; padding: 4px; cursor: pointer; color: inherit;
  display: grid; place-items: center;
}
.fd-card-actions img,
.fd-card-actions svg { width: 16px; height: 16px; }
.fd-card-actions img {
  filter: invert(27%) sepia(89%) saturate(2846%) hue-rotate(244deg) brightness(92%) contrast(93%);
}
.fd-card-actions svg path { fill: currentColor; }

.fd-corp-card {
  width: 273px;
  height: 130px;
  padding: 16px;
  border-radius: 12px;
  border: 1px solid var(--fd-border-input);
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-sizing: border-box;
}
.fd-corp-card.is-hover,
.fd-corp-card:hover {
  border-color: var(--fd-action-primary);
  box-shadow: var(--fd-shadow-card);
}
.fd-corp-card .fd-card-title { font-size: 15px; line-height: 20px; }
.fd-card-pills { display: flex; flex-wrap: wrap; gap: 12px; }
.fd-card-pill {
  display: inline-flex;
  align-items: center;
  height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--gray-75);
  font-size: 13px;
  line-height: 20px;
  color: var(--fd-text-secondary);
}
.fd-card-pill strong {
  font-weight: 500;
  color: var(--fd-text-primary);
  margin-right: 4px;
}

.fd-builder-card {
  width: 273px;
  padding: 20px;
  border-radius: 12px;
  border: 1px solid var(--fd-border-input);
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-sizing: border-box;
}
.fd-builder-card .fd-card-title {
  font-size: 17px;
  line-height: 24px;
  font-weight: 600;
}
.fd-builder-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.fd-builder-meta .fd-card-meta-row {
  font-size: 13px;
  line-height: 18px;
  color: var(--fd-text-primary);
}
.fd-long-card {
  display: flex; align-items: center; gap: 16px;
  width: 100%; max-width: 982px;
  padding: 20px 24px;
  border-radius: 12px;
  border: 1px solid var(--fd-border-default);
  background: #fff;
}
.fd-long-card.noline { border: 0; box-shadow: var(--fd-shadow-card); }
/* ---- Tooltip ---- */
.fd-tooltip {
  display: inline-flex;
  align-items: center;
  padding: 8px 10px;
  border-radius: 6px;
  background: var(--gray-900);
  color: #fff;
  font-size: 12px;
  line-height: 16px;
  position: relative;
  white-space: nowrap;
}
.fd-tooltip.stroke { box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); }

/* Floating “Copied to clipboard” tip for [data-copy] controls */
.fd-copy-tip {
  position: fixed;
  z-index: 14000;
  pointer-events: none;
  opacity: 0;
  transition: opacity 160ms ease;
  transform: translate(-50%, -100%);
}
.fd-copy-tip[data-placement="below"] {
  transform: translate(-50%, 0);
}
.fd-copy-tip.is-visible {
  opacity: 1;
}
.fd-copy-tip .fd-tooltip::after {
  content: "";
  position: absolute;
  left: 50%;
  width: 8px;
  height: 8px;
  margin-left: -4px;
  background: var(--gray-900);
  transform: rotate(45deg);
}
.fd-copy-tip:not([data-placement="below"]) .fd-tooltip::after {
  top: 100%;
  margin-top: -4px;
}
.fd-copy-tip[data-placement="below"] .fd-tooltip::after {
  bottom: 100%;
  margin-bottom: -4px;
}

/* ---- Date picker field ---- */
.fd-date {
  display: inline-flex; align-items: center; justify-content: space-between;
  width: 230px; height: 40px; padding: 0 12px;
  border: 1px solid var(--fd-border-input);
  border-radius: var(--fd-r-control);
  background: #fff;
  color: var(--fd-text-secondary);
  font-size: 14px; cursor: pointer;
}
.fd-date svg { width: 16px; height: 16px; color: var(--fd-text-muted); }

/* ---- Popover ---- */
.fd-popover {
  width: 256px;
  padding: 14px;
  border-radius: 8px;
  border: 1px solid var(--fd-border-default);
  background: #fff;
  box-shadow: var(--fd-shadow-card);
}
.fd-popover-title {
  margin: 0 0 6px;
  font-size: 14px; font-weight: 700; color: var(--fd-text-primary);
}
.fd-popover-body {
  margin: 0;
  font-size: 13px; line-height: 18px; color: var(--fd-text-secondary);
}

/* ---- Left navigation ---- */
.fd-leftnav {
  display: flex;
  flex-direction: column;
  width: 232px;
  min-height: 520px;
  padding: 32px 40px 40px;
  background: var(--fd-bg-page);
  box-sizing: border-box;
}
.fd-leftnav-brand {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--fd-border-default);
  margin-bottom: 28px;
}
.fd-leftnav-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #1a1a2e;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -.02em;
}
.fd-leftnav-logo svg { width: 22px; height: 22px; flex: none; }
.fd-leftnav-sub {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--fd-text-muted);
}
.fd-leftnav-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
  flex: 1;
}
.fd-leftnav-item {
  appearance: none;
  -webkit-appearance: none;
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  width: 184px;
  min-height: 40px;
  margin-left: -16px;
  padding: 8px 16px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--fd-text-secondary);
  font-size: 14px;
  line-height: 20px;
  text-align: left;
  cursor: pointer;
}
.fd-leftnav-item svg {
  width: 24px;
  height: 24px;
  flex: none;
  color: inherit;
}
.fd-leftnav-item svg path { fill: currentColor; }
.fd-leftnav-item.is-active {
  background: var(--fd-action-primary-subtle);
  color: var(--fd-action-primary);
}
.fd-leftnav-item:hover:not(.is-active) {
  color: var(--fd-text-primary);
}
.fd-leftnav-foot {
  margin-top: auto;
  padding-top: 32px;
}
.fd-leftnav-logout {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 0;
  background: transparent;
  color: var(--fd-text-secondary);
  font-size: 14px;
  line-height: 20px;
  cursor: pointer;
  padding: 0;
}
.fd-leftnav-logout svg { width: 24px; height: 24px; color: inherit; }
.fd-leftnav-logout svg path { fill: currentColor; }

/* ---- Dialog / side panel ---- */
.fd-dialog {
  width: 100%;
  max-width: 600px;
  background: var(--fd-bg-page);
  border: 1px solid var(--fd-border-default);
  border-radius: 0;
  box-shadow: var(--fd-shadow-card);
}
.fd-panel-hd {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  padding: 24px;
  background: #fff;
  border-bottom: 1px solid var(--fd-border-default);
  box-sizing: border-box;
}
.fd-panel-hd h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  line-height: 24px;
  color: var(--fd-text-primary);
}
.fd-panel-close {
  width: 16px;
  height: 16px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--fd-text-muted);
  cursor: pointer;
  display: grid;
  place-items: center;
  flex: none;
}
.fd-panel-close svg { width: 16px; height: 16px; }
.fd-dialog-body {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 24px;
}
.fd-dialog-foot {
  display: flex;
  justify-content: flex-end;
  padding: 0 24px 24px;
}

/* ---- Date picker panel ---- */
.fd-date-panel {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 842px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 45px rgba(34, 40, 49, 0.2);
  overflow: hidden;
}
.fd-date-main {
  display: flex;
  align-items: stretch;
  min-height: 0;
}
.fd-date-presets {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 32px 28px;
  border-right: 1px solid var(--fd-border-default);
  font-size: 14px;
  line-height: 20px;
  color: var(--fd-text-primary);
  white-space: nowrap;
}
.fd-date-preset {
  border: 0;
  background: transparent;
  padding: 0;
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
}
.fd-date-preset:hover,
.fd-date-preset.is-active { color: var(--fd-action-primary); font-weight: 600; }
.fd-date-cals {
  display: flex;
  flex: 1;
  min-width: 0;
}
.fd-cal {
  flex: 1;
  padding: 28px 24px;
  border-right: 1px solid var(--fd-border-default);
}
.fd-cal:last-child { border-right: 0; }
.fd-cal-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.fd-cal-hd .fd-cal-title {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  line-height: 24px;
  color: var(--fd-text-primary);
}
.fd-cal-nav {
  border: 0;
  background: transparent;
  color: var(--fd-text-secondary);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}
.fd-cal-weekdays,
.fd-cal-week {
  display: flex;
}
.fd-cal-dow,
.fd-cal-day {
  width: 44px;
  height: 40px;
  display: grid;
  place-items: center;
  font-size: 14px;
  line-height: 20px;
  color: var(--fd-text-primary);
  position: relative;
}
.fd-cal-dow {
  height: 28px;
  font-size: 12px;
  line-height: 18px;
  color: var(--fd-text-secondary);
  text-transform: capitalize;
}
.fd-cal-day.muted { color: var(--fd-text-muted); }
.fd-cal-day.in-range::before {
  content: "";
  position: absolute;
  inset: 4px 0;
  background: var(--fd-action-primary-subtle);
  z-index: 0;
}
.fd-cal-day.range-start::before { left: 50%; border-radius: 0 0 0 0; }
.fd-cal-day.range-end::before { right: 50%; }
.fd-cal-day.range-start.range-end::before { display: none; }
.fd-cal-day span {
  position: relative;
  z-index: 1;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  display: grid;
  place-items: center;
}
.fd-cal-day.range-start span,
.fd-cal-day.range-end span {
  background: var(--fd-action-primary);
  color: #fff;
  font-weight: 600;
}
.fd-cal-day.in-range:not(.range-start):not(.range-end) span {
  color: var(--fd-action-primary-pressed);
}
.fd-date-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  border-top: 1px solid var(--fd-border-default);
  flex-wrap: wrap;
}
.fd-date-range-vals {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--fd-text-secondary);
}
.fd-date-range-vals .fd-input {
  width: 140px;
  height: 36px;
  text-align: center;
}
.fd-date-actions { display: flex; gap: 12px; }

/* ---- Top navigation ---- */
.fd-topnav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 980px;
  height: 74px;
  padding: 0 40px;
  background: var(--fd-bg-page);
  box-shadow: var(--fd-shadow-card);
  box-sizing: border-box;
}
.fd-topnav-left {
  display: flex;
  align-items: center;
  gap: 48px;
}
.fd-topnav-brand {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.fd-topnav-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 700;
  color: var(--fd-text-primary);
}
.fd-topnav-logo svg { width: 20px; height: 20px; }
.fd-topnav-sub {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .02em;
  color: var(--gray-700);
}
.fd-topnav-divider {
  width: 1px;
  height: 40px;
  background: var(--fd-border-default);
}
.fd-topnav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}
.fd-topnav-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--fd-text-primary);
  font-size: 14px;
  line-height: 20px;
  cursor: pointer;
}
.fd-topnav-link svg { width: 24px; height: 24px; color: inherit; }
.fd-topnav-link svg path { fill: currentColor; }
.fd-topnav-link.is-active {
  background: var(--fd-action-primary-subtle);
  color: var(--fd-action-primary);
  border-radius: 8px;
}
.fd-topnav-right {
  display: flex;
  align-items: center;
  gap: 32px;
}
.fd-topnav-icon {
  width: 32px; height: 32px;
  border: 0; background: transparent;
  color: var(--fd-icon-default);
  display: grid; place-items: center;
  cursor: pointer; padding: 0;
}
.fd-topnav-icon svg { width: 20px; height: 20px; }
.fd-topnav-avatar {
  width: 32px; height: 32px; border-radius: 16px;
  background: var(--fd-action-primary-subtle);
  color: var(--fd-action-primary);
  display: grid; place-items: center;
  font-size: 11px; font-weight: 600;
}

/* ---- Breadcrumb dropdown (see .fd-crumbs-dd above) ---- */


/* ---- Interactive card ---- */
.fd-interactive-card {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 228px;
  padding: 12px 24px;
  border-radius: 12px;
  border: 1px solid var(--fd-border-default);
  background: var(--fd-bg-page);
  box-shadow: var(--fd-shadow-card);
  box-sizing: border-box;
  cursor: pointer;
  color: var(--fd-text-primary);
  font-family: inherit;
  font-size: 17px;
  font-weight: 600;
  line-height: 24px;
}
.fd-interactive-card img,
.fd-interactive-card svg { width: 24px; height: 24px; flex: none; }
.fd-interactive-card.is-hover,
.fd-interactive-card:hover {
  border-color: var(--fd-action-primary);
  color: var(--fd-text-link);
}
.fd-interactive-card.is-hover img,
.fd-interactive-card:hover img {
  filter: invert(27%) sepia(89%) saturate(2846%) hue-rotate(244deg) brightness(92%) contrast(93%);
}

.fd-builder-card .fd-card-pill { height: 32px; }
.fd-corp-card .fd-card-title { margin: 0; }
.fd-builder-card .fd-card-id { margin: 0; }
