.interactive-demo .tg-workbench {
  --tg-ink: #122923;
  --tg-muted: #50675e;
  --tg-faint: #62766c;
  --tg-accent: #116858;
  --tg-strong: #087e71;
  --tg-line: #dce8df;
  --tg-mist: #e9f3ec;
  --tg-paper: #fff;
  --tg-soft: #f7faf7;
  container: tg-workbench / inline-size;
  min-width: 0;
  color: var(--tg-ink);
  background: var(--tg-paper);
  border: 1px solid #cfded3;
  border-radius: 18px;
  box-shadow: 0 18px 42px rgba(25, 70, 50, 0.10), 0 3px 8px rgba(25, 70, 50, 0.05);
  font-family: inherit;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.4;
  text-align: left;
}

.interactive-demo .tg-workbench *,
.interactive-demo .tg-workbench *::before,
.interactive-demo .tg-workbench *::after {
  box-sizing: border-box;
}

.interactive-demo .tg-workbench :where(p, h3, ul, ol) {
  margin: 0;
  padding: 0;
}

.interactive-demo .tg-workbench :where(ul, ol) {
  list-style: none;
}

.interactive-demo .tg-workbench :where(button, input) {
  font: inherit;
}

.interactive-demo .tg-workbench :where(button) {
  cursor: pointer;
}

.interactive-demo .tg-workbench button:focus-visible,
.interactive-demo .tg-workbench input:focus-visible {
  outline: 2px solid var(--tg-strong);
  outline-offset: 2px;
}

.interactive-demo .tg-workbench [hidden] {
  display: none;
}

.interactive-demo .tg-demo-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.interactive-demo .tg-demo-chrome {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 56px;
  padding: 10px 14px;
  background: #f9fcf8;
  border-bottom: 1px solid var(--tg-line);
  border-radius: 17px 17px 0 0;
}

.interactive-demo .tg-demo-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: none;
  font-size: 15px;
  font-weight: 760;
  letter-spacing: -0.025em;
}

.interactive-demo .tg-demo-logo {
  display: block;
  flex: 0 0 25px;
  width: 25px;
  height: 25px;
  border-radius: 7px;
}

.interactive-demo .tg-demo-sample {
  color: var(--tg-muted);
  font-size: 12px;
  letter-spacing: 0.012em;
  padding-left: 10px;
  border-left: 1px solid var(--tg-line);
}

.interactive-demo .tg-demo-reset {
  display: inline-flex;
  align-items: center;
  align-self: center;
  gap: 5px;
  min-height: 34px;
  padding: 2px 9px;
  margin-left: auto;
  border: 1px solid #d3e1d7;
  border-radius: 7px;
  color: var(--tg-muted);
  background: #fff;
  font-size: 13px;
  font-weight: 660;
}

.interactive-demo .tg-demo-reset span[aria-hidden] {
  color: var(--tg-accent);
  font-size: 15px;
  line-height: 1;
}

.interactive-demo .tg-demo-reset:hover {
  border-color: #90afa1;
  color: var(--tg-ink);
}

.interactive-demo .tg-demo-columns {
  display: grid;
  grid-template-columns: minmax(115px, 0.78fr) minmax(0, 1.66fr) minmax(155px, 1.18fr);
  grid-template-areas: "nav main side";
  min-height: 314px;
}

.interactive-demo .tg-demo-sidebar {
  grid-area: nav;
  min-width: 0;
  padding: 15px 9px;
  background: var(--tg-soft);
  border-right: 1px solid var(--tg-line);
}

.interactive-demo .tg-demo-directory {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 25px;
  margin-bottom: 9px;
  padding: 0 3px;
  color: var(--tg-muted);
  font-size: 12px;
  line-height: 1.25;
  font-weight: 720;
}

.interactive-demo .tg-demo-directory-icon {
  display: inline-block;
  position: relative;
  flex: 0 0 12px;
  height: 12px;
  background: linear-gradient(var(--tg-muted), var(--tg-muted)) 0 0 / 5px 5px no-repeat,
    linear-gradient(var(--tg-muted), var(--tg-muted)) 7px 0 / 5px 5px no-repeat,
    linear-gradient(var(--tg-muted), var(--tg-muted)) 0 7px / 5px 5px no-repeat,
    linear-gradient(var(--tg-muted), var(--tg-muted)) 7px 7px / 5px 5px no-repeat;
  opacity: 0.85;
}

.interactive-demo .tg-demo-collection-list {
  display: grid;
  gap: 5px;
}

.interactive-demo .tg-demo-nav-item {
  display: grid;
  grid-template-columns: 13px minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
  width: 100%;
  min-height: 38px;
  padding: 5px 6px;
  text-align: left;
  border: 1px solid transparent;
  border-radius: 7px;
  color: var(--tg-muted);
  background: transparent;
  font-size: 12px;
  font-weight: 620;
  line-height: 1.2;
}

.interactive-demo .tg-demo-nav-item:hover {
  background: var(--tg-mist);
}

.interactive-demo .tg-demo-nav-item[aria-pressed="true"] {
  border-color: #c5e4d5;
  color: #0e5c4f;
  background: #dcefe5;
}

.interactive-demo .tg-demo-nav-name {
  overflow-wrap: anywhere;
}

.interactive-demo .tg-demo-nav-count,
.interactive-demo .tg-demo-side-count {
  font-size: 12px;
  line-height: 1;
  font-weight: 700;
  color: var(--tg-faint);
  font-variant-numeric: tabular-nums;
}

.interactive-demo .tg-demo-folder {
  display: inline-block;
  position: relative;
  width: 12px;
  height: 9px;
  color: #7e699f;
  border: 1px solid currentColor;
  border-radius: 2px;
}

.interactive-demo .tg-demo-folder::before {
  content: "";
  position: absolute;
  top: -3px;
  left: -1px;
  width: 6px;
  height: 3px;
  border: 1px solid currentColor;
  border-bottom: 0;
  border-radius: 2px 2px 0 0;
  transform: skew(10deg);
}

.interactive-demo .tg-demo-folder.tg-demo-tone-mint,
.interactive-demo .tg-demo-tone-mint .tg-demo-folder {
  color: #33735c;
}

.interactive-demo .tg-demo-folder.tg-demo-tone-sand,
.interactive-demo .tg-demo-tone-sand .tg-demo-folder {
  color: #86602a;
}

.interactive-demo .tg-demo-main {
  grid-area: main;
  min-width: 0;
  padding: 15px 13px 17px;
}

.interactive-demo .tg-demo-main-header {
  display: grid;
  gap: 11px;
  margin-bottom: 13px;
}

.interactive-demo .tg-demo-collection-header {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 31px;
}

.interactive-demo .tg-demo-collection-header h3 {
  color: var(--tg-ink);
  font-size: 17px;
  line-height: 1.22;
  font-weight: 740;
  letter-spacing: -0.028em;
}

.interactive-demo .tg-demo-collection-header p {
  color: var(--tg-muted);
  font-size: 12px;
  margin-top: 3px;
}

.interactive-demo .tg-demo-panel-icon {
  display: grid;
  flex: 0 0 31px;
  place-items: center;
  width: 31px;
  height: 31px;
  border-radius: 8px;
}

.interactive-demo .tg-demo-panel-icon.tg-demo-tone-lavender,
.interactive-demo .tg-demo-link-badge.tg-demo-tone-lavender {
  color: #5c4492;
  background: #eeeaf9;
}

.interactive-demo .tg-demo-panel-icon.tg-demo-tone-mint,
.interactive-demo .tg-demo-link-badge.tg-demo-tone-mint {
  color: #28654f;
  background: #e2f1e6;
}

.interactive-demo .tg-demo-panel-icon.tg-demo-tone-sand,
.interactive-demo .tg-demo-link-badge.tg-demo-tone-sand {
  color: #805922;
  background: #f4eee0;
}

.interactive-demo .tg-demo-search {
  position: relative;
  display: block;
  min-width: 0;
}

.interactive-demo .tg-demo-search input {
  display: block;
  width: 100%;
  min-height: 38px;
  padding: 5px 7px 5px 28px;
  border: 1px solid var(--tg-line);
  border-radius: 7px;
  color: var(--tg-ink);
  background: #f9fbf9;
  font-size: 13px;
  line-height: 1.25;
  box-shadow: none;
}

.interactive-demo .tg-demo-search input::placeholder {
  color: var(--tg-faint);
  opacity: 1;
}

.interactive-demo .tg-demo-search-icon {
  position: absolute;
  top: 13px;
  left: 10px;
  z-index: 1;
  width: 9px;
  height: 9px;
  color: var(--tg-faint);
  border: 1.5px solid currentColor;
  border-radius: 50%;
  pointer-events: none;
}

.interactive-demo .tg-demo-search-icon::after {
  content: "";
  position: absolute;
  right: -4px;
  bottom: -2px;
  width: 4px;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(48deg);
}

.interactive-demo .tg-demo-drop-area {
  min-height: 100px;
  padding: 1px;
  border: 1px solid transparent;
  border-radius: 8px;
}

.interactive-demo .tg-demo-drop-active {
  outline: 2px dashed #63a693;
  outline-offset: 1px;
  background: #e6f6ed;
}

.interactive-demo.tg-demo-dragging .tg-demo-drop-hint {
  border-color: #79b49f;
  background: #eff8f1;
}

.interactive-demo .tg-demo-link-list {
  display: grid;
  gap: 7px;
}

.interactive-demo .tg-demo-saved-link {
  min-width: 0;
  border: 1px solid var(--tg-line);
  border-radius: 8px;
  background: #fff;
}

.interactive-demo .tg-demo-link-row {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  min-height: 56px;
  padding: 6px 7px;
}

.interactive-demo .tg-demo-link-row[draggable] {
  cursor: grab;
}

.interactive-demo .tg-demo-link-badge {
  display: grid;
  place-items: center;
  flex: 0 0 25px;
  width: 25px;
  height: 25px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 780;
  line-height: 1;
}

.interactive-demo .tg-demo-link-details {
  display: grid;
  flex: 1 1 auto;
  gap: 2px;
  min-width: 0;
}

.interactive-demo .tg-demo-link-name {
  display: block;
  color: var(--tg-ink);
  font-size: 14px;
  font-weight: 680;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.interactive-demo .tg-demo-link-subtitle {
  display: block;
  color: var(--tg-faint);
  font-size: 12px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.interactive-demo .tg-demo-drop-hint,
.interactive-demo .tg-demo-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 48px;
  padding: 8px;
  text-align: center;
  color: var(--tg-muted);
  font-size: 12px;
  line-height: 1.3;
}

.interactive-demo .tg-demo-drop-hint {
  margin-top: 8px;
  border: 1px dashed #c7dbcf;
  border-radius: 8px;
  background: #f7faf7;
}

.interactive-demo .tg-demo-drop-hint span {
  font-size: 16px;
  font-weight: 630;
  line-height: 1;
  color: var(--tg-accent);
}

.interactive-demo .tg-demo-sidepanel {
  grid-area: side;
  min-width: 0;
  padding: 17px 11px 14px;
  background: #f8fbf8;
  border-left: 1px solid var(--tg-line);
}

.interactive-demo .tg-demo-side-heading {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 23px;
  margin-bottom: 7px;
}

.interactive-demo .tg-demo-side-heading h3 {
  margin-right: auto;
  color: var(--tg-ink);
  font-size: 14px;
  font-weight: 735;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.interactive-demo .tg-demo-live-dot,
.interactive-demo .tg-demo-status-dot {
  display: inline-block;
  flex: 0 0 6px;
  width: 6px;
  height: 6px;
  background: #3b8860;
  border-radius: 50%;
}

.interactive-demo .tg-demo-open-list {
  display: grid;
  gap: 7px;
}

.interactive-demo .tg-demo-open-row {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  min-height: 52px;
  padding: 6px 5px;
  border: 1px solid var(--tg-line);
  border-radius: 8px;
  background: #fff;
}

.interactive-demo .tg-demo-open-row {
  cursor: grab;
}

.interactive-demo .tg-demo-open-row:active,
.interactive-demo .tg-demo-link-row[draggable]:active {
  cursor: grabbing;
}

.interactive-demo .tg-demo-open-row .tg-demo-link-badge {
  flex-basis: 19px;
  width: 19px;
  height: 19px;
  font-size: 9px;
  border-radius: 4px;
}

.interactive-demo .tg-demo-grip {
  flex: 0 0 7px;
  width: 7px;
  height: 12px;
  background: radial-gradient(circle, #789484 0.75px, transparent 1px) 0 0 / 3.5px 4px;
}

.interactive-demo .tg-demo-save,
.interactive-demo .tg-demo-move,
.interactive-demo .tg-demo-open,
.interactive-demo .tg-demo-picker button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-height: 34px;
  padding: 4px 7px;
  white-space: nowrap;
  border: 1px solid #cde3d7;
  border-radius: 5px;
  color: var(--tg-accent);
  background: #eaf5ed;
  font-size: 14px;
  font-weight: 740;
  line-height: 1.2;
}

.interactive-demo .tg-demo-save:hover,
.interactive-demo .tg-demo-move:hover,
.interactive-demo .tg-demo-open:hover,
.interactive-demo .tg-demo-picker button:hover {
  border-color: #98c4b0;
  background: #dcefe5;
}

.interactive-demo .tg-demo-saved {
  color: #396a54;
  background: #f4faf4;
  border-color: #e1ede2;
  cursor: default;
}

.interactive-demo .tg-demo-move {
  background: #f7faf7;
}

.interactive-demo .tg-demo-row-actions {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  flex: 0 0 auto;
}

.interactive-demo .tg-demo-picker {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 6px;
  padding: 7px;
  border-top: 1px solid var(--tg-line);
  background: #f7faf7;
  border-radius: 0 0 7px 7px;
}

.interactive-demo .tg-demo-picker p {
  width: 100%;
  color: var(--tg-muted);
  font-size: 12px;
}

.interactive-demo .tg-demo-picker button {
  white-space: normal;
}

.interactive-demo .tg-demo-side-empty {
  color: var(--tg-muted);
  font-size: 12px;
  line-height: 1.4;
}

.interactive-demo .tg-demo-activity-list {
  display: grid;
  gap: 8px;
}

.interactive-demo .tg-demo-activity-list li {
  position: relative;
  padding-left: 10px;
  color: #37574b;
  font-size: 12px;
  line-height: 1.35;
}

.interactive-demo .tg-demo-activity-list li::before {
  content: "";
  position: absolute;
  top: 0.48em;
  left: 0;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #51a882;
}

.interactive-demo .tg-demo-preview {
  margin-top: 12px;
  padding: 9px;
  border: 1px solid #d2e5d8;
  border-radius: 8px;
  background: #fff;
}

.interactive-demo .tg-demo-preview:focus {
  outline: 2px solid var(--tg-strong);
  outline-offset: 2px;
}

.interactive-demo .tg-demo-preview-label {
  margin-bottom: 7px;
  color: var(--tg-muted);
  font-size: 12px;
  font-weight: 630;
}

.interactive-demo .tg-demo-preview-heading {
  display: flex;
  align-items: center;
  gap: 6px;
}

.interactive-demo .tg-demo-preview-summary {
  margin-top: 7px;
  color: var(--tg-muted);
  font-size: 12px;
}

.interactive-demo .tg-demo-footer {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 43px;
  padding: 8px 13px;
  color: #365e4f;
  background: #edf7ee;
  border-top: 1px solid #d5e8da;
  border-radius: 0 0 17px 17px;
}

.interactive-demo .tg-demo-status {
  flex: 1 1 auto;
  font-size: 12px;
  font-weight: 580;
  line-height: 1.35;
}

@container tg-workbench (max-width: 550px) {
  .interactive-demo .tg-demo-columns {
    grid-template-columns: minmax(106px, 0.65fr) minmax(0, 1.7fr);
    grid-template-areas: "nav main" "side side";
    min-height: 0;
  }

  .interactive-demo .tg-demo-sidepanel {
    border-top: 1px solid var(--tg-line);
    border-left: 0;
  }

  .interactive-demo[data-demo="save"] .tg-demo-open-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .interactive-demo .tg-demo-open-row {
    align-items: start;
    flex-wrap: wrap;
  }

  .interactive-demo .tg-demo-open-row .tg-demo-link-details {
    flex-basis: calc(100% - 31px);
    min-height: 29px;
  }

  .interactive-demo .tg-demo-open-row .tg-demo-save {
    margin-left: auto;
  }

  .interactive-demo .tg-demo-main {
    padding-bottom: 13px;
  }

  .interactive-demo .tg-demo-open,
  .interactive-demo .tg-demo-save,
  .interactive-demo .tg-demo-move,
  .interactive-demo .tg-demo-picker button,
  .interactive-demo .tg-demo-nav-item,
  .interactive-demo .tg-demo-reset {
    min-height: 44px;
  }

  .interactive-demo .tg-demo-open,
  .interactive-demo .tg-demo-save,
  .interactive-demo .tg-demo-move,
  .interactive-demo .tg-demo-picker button {
    padding-inline: 9px;
  }

  .interactive-demo .tg-demo-search input {
    min-height: 42px;
    font-size: 16px;
  }

  .interactive-demo .tg-demo-search-icon {
    top: 15px;
  }
}

@container tg-workbench (max-width: 390px) {
  .interactive-demo .tg-demo-columns {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "nav" "main" "side";
  }

  .interactive-demo .tg-demo-sidebar {
    padding: 7px 9px;
    border-right: 0;
    border-bottom: 1px solid var(--tg-line);
  }

  .interactive-demo .tg-demo-directory {
    margin-bottom: 3px;
  }

  .interactive-demo .tg-demo-collection-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .interactive-demo[data-demo="save"] .tg-demo-collection-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .interactive-demo[data-demo="save"] .tg-demo-open-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .interactive-demo .tg-demo-open-row {
    align-items: center;
    flex-wrap: nowrap;
  }

  .interactive-demo .tg-demo-open-row .tg-demo-link-details {
    flex-basis: auto;
    min-height: 0;
  }

  .interactive-demo .tg-demo-open-row .tg-demo-save {
    margin-left: 0;
  }

  .interactive-demo .tg-demo-main-header {
    grid-template-columns: minmax(0, 1fr) minmax(102px, 0.9fr);
    align-items: center;
    gap: 8px;
  }

  .interactive-demo .tg-demo-sidepanel {
    padding: 10px 11px;
  }

  .interactive-demo .tg-demo-side-heading {
    min-height: 18px;
  }
}
