.organigram{
  display:flex; overflow:visible;
  --org-elbow-r:var(--md-radius-80,8px);
  --org-sibling-gap:var(--md-spacing-32,32px);
  --org-sibling-gap-max:96px;
  --org-gap-v:32px;
  --org-gap-v-max:64px;
  --org-gap-h:24px;
  --org-gap-h-max:96px;
  --org-node-min-w:240px;
  --org-node-max-w:320px;
}
.org-chart-scroll{ width:100%; height:100%; min-height:0; overflow:auto; display:flex; align-items:center; align-items:safe center; justify-content:center; justify-content:safe center; padding:32px 24px; box-sizing:border-box; }
.org-node-wrap{ display:flex; flex-direction:column; align-items:center; }
.org-chart-scroll > .org-node-wrap{ flex:none; }
.org-node{
  position:relative; display:inline-grid; grid-template-columns:auto minmax(0,1fr);
  align-content:center; align-items:start; column-gap:16px;
  padding:12px 16px 12px 16px; border-radius:var(--md-radius-240,24px);
  background:var(--md-neutral-background-1-rest); border:1px solid var(--md-neutral-stroke-1-rest);
  cursor:pointer; min-width:var(--org-node-min-w); width:fit-content; max-width:var(--org-node-max-w);
}
.org-node.node-focused{ outline:2px solid var(--ui-accent); outline-offset:2px; }
.org-node-icon{
  flex-shrink:0; width:32px; height:28px; border-radius:12px;
  color:var(--md-brand-foreground-1-rest);
  display:flex; align-items:center; justify-content:center;
}
.org-node-icon i{ font-size:var(--md-typography-font-size-500); }
.org-node-text{ display:flex; flex-direction:column; gap:2px; text-align:left; min-width:0; }
.org-node-title{ font-family:var(--font-display); font-weight:var(--font-weight-light); font-size:var(--md-typography-font-size-500); line-height:28px; color:var(--md-neutral-foreground-1-rest); outline:none; width:fit-content; max-width:100%; overflow-wrap:anywhere; }
.org-node-desc{ font-family:var(--font-sans); font-weight:var(--font-weight-light); font-size:var(--md-typography-font-size-400); line-height:22px; color:var(--md-neutral-foreground-3-rest); outline:none; width:fit-content; max-width:100%; overflow-wrap:anywhere; }
.org-node-desc:empty{ display:none; }
.org-node[data-style="accent"]{ background:var(--md-brand-background-inverted-rest); border-color:transparent; }
.org-node[data-style="accent"] .org-node-icon{ color:var(--md-color-grey-white); }
.org-node[data-style="accent"] .org-node-title{ color:var(--md-color-grey-white); }
.org-node[data-style="accent"] .org-node-desc{ color:rgba(255,255,255,0.8); }
.org-node[data-style="accent"] [data-placeholder]:empty:before{ color:rgba(255,255,255,0.6); }
.org-btn{ border:none; cursor:pointer; display:flex; align-items:center; justify-content:center; padding:0; }
.org-btn-delete{
  position:absolute; top:-8px; right:-8px; width:20px; height:20px; border-radius:50%;
  background:var(--slide-surface); color:var(--md-neutral-foreground-3-rest); font-size:11px;
  box-shadow:0 1px 3px rgba(20,30,50,0.25); opacity:0; transition:opacity .1s; z-index:3;
}
.org-node:hover .org-btn-delete{ opacity:1; }
.org-node-actions{
  position:absolute; left:50%; bottom:0; transform:translate(-50%,50%);
  display:flex; align-items:center; gap:6px; opacity:0; pointer-events:none; transition:opacity .1s; z-index:2;
}
.org-node:hover .org-node-actions, .org-node.node-focused .org-node-actions{ opacity:1; pointer-events:auto; }
.org-btn-add{
  width:22px; height:22px; border-radius:50%; background:var(--md-brand-background-inverted-rest); color:var(--md-color-grey-white);
  font-size:11px; box-shadow:0 1px 3px rgba(20,30,50,0.25);
}
.deck-component.organigram[data-color="teal"]{
  --md-brand-foreground-1-rest:var(--md-teal-foreground-1-rest);
  --md-brand-background-inverted-rest:var(--md-teal-background-inverted-rest);
}
.deck-component.organigram[data-color="pink"]{
  --md-brand-foreground-1-rest:var(--md-pink-foreground-1-rest);
  --md-brand-background-inverted-rest:var(--md-pink-background-inverted-rest);
}
.deck-component.organigram[data-color="grey"]{
  --md-brand-foreground-1-rest:var(--md-neutral-foreground-1-rest);
  --md-brand-background-inverted-rest:var(--md-neutral-foreground-1-rest);
}
.org-children-wrap{ position:relative; display:flex; flex-direction:column; align-items:center; padding-top:var(--org-gap-v); }
.org-connectors{ position:absolute; inset:0; width:100%; height:100%; overflow:visible; pointer-events:none; z-index:0; }
.org-connectors path{ fill:none; stroke:var(--md-neutral-stroke-1-rest); stroke-width:2px; }
.org-children-row{ position:relative; z-index:1; display:flex; gap:var(--org-sibling-gap); align-items:center; }
.deck-component.organigram:not([data-orientation="horizontal"]) .org-children-row{ align-items:flex-start; }

.deck-component.organigram[data-orientation="horizontal"]{ --org-sibling-gap:var(--md-spacing-24,24px); --org-sibling-gap-max:48px; }
.deck-component.organigram[data-orientation="horizontal"] .org-node-wrap{ flex-direction:row; }
.deck-component.organigram[data-orientation="horizontal"] .org-children-wrap{ flex-direction:row; padding-top:0; padding-left:var(--org-gap-h); }
.deck-component.organigram[data-orientation="horizontal"] .org-children-row{ flex-direction:column; align-items:flex-start; }
.deck-component.organigram[data-orientation="horizontal"] .org-node-actions{ left:100%; top:50%; bottom:auto; transform:translate(-50%,-50%); flex-direction:column; }
.deck-component.organigram[data-orientation="horizontal"] .org-btn-delete{ top:50%; left:-8px; right:auto; transform:translateY(-50%); }

.org-gap-spacer{ display:none; }

.org-color-row{ display:flex; align-items:center; gap:8px; }

