#overview.schema {
  display: flex;
  min-height: 100%;

  .node-row {
    flex: 1 0 auto;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    align-items: center;
    gap: 4em;
    padding: 5em;
  }

  #node-container {
    display: flex;
    transition: all 0.5ms ease-in-out;
  }

  .node-view {
    position: initial;

    .action-button {
      /* margin-left: auto; */
      width: 1.5em;
      background-color: var(--dark-gray);
      border-radius: 50%;
      outline: 1px solid black;
      --base-transform: scale(1.05);
      transform: var(--base-transform);
      transition: all 0.4s ease-in-out;
      opacity: 1;

      svg {
        display: block;
        cursor: pointer;
      }

      &.remove {
        padding: 6px;
      }

      &.swap {
        padding: 5px;
      }

      &.config {
        padding: 0.25em;
        color: var(--disabled-bg);

        &.active {
          transform: var(--base-transform) rotateZ(440deg);
          background: var(--primary);
          color: var(--white);
        }
      }

      &:hover {
        scale: 1.1;
      }

      &[disabled] {
        opacity: 0.7;
      }
    }

    .config-container {
      display: flex;
      align-items: center;
      gap: 1em;
      width: 100%;
      padding: 0.5em;
      background: var(--dark-gray);
      border: 1px solid black;
      border-radius: 5px;
      margin-right: 1.5em;

      button.active {
        background-color: var(--primary);
      }
    }
  }

  input.input-name {
    box-shadow: unset;
    color: var(--white);
    background-color: var(--bg-alt);
    padding: 4px;
    width: 12em;
  }

  .swap-order {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    margin-right: 8px;

    .chevron-box {
      all: unset;
      color: var(--primary);
      background-color: var(--dark-gray);
      cursor: pointer;
      border-radius: 50%;
      padding: 2px;
      display: grid;
      align-items: center;
      outline: 1px solid black;
    }

    .svg-chevron-down,
    .svg-chevron-up {
      width: 10px;
    }
  }

  .action-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5em;
    border-radius: 0.5em;
    background-color: var(--bg-active);
    outline: 1px solid var(--dark-gray);
    flex: 1;
    gap: 0.5em;

    &.margin-right {
      margin-right: 1.5em;
    }

    .status {
      color: black;
      font-weight: bold;
    }
  }

  .formula-view {
    display: flex;
    flex-direction: column;
    padding: 1.5em;
    z-index: 5;
    border-radius: 5px;
    background-color: var(--bg);
    box-shadow: 2px 2px 6px var(--dark-gray);
    border: 1px solid var(--dark-gray);
    transition: transform 0.2s ease-in-out;
    gap: 1em;
    box-shadow: 2px 2px 6px var(--dark-gray);

    &:hover,
    &.active {
      border: 1px solid var(--bg-active);
    }

    .header-container {
      display: flex;
      gap: 1em;
      align-items: center;
    }
  }

  .enum-view {
    display: flex;
    flex-direction: column;
    padding: 1.5em;
    z-index: 5;
    border-radius: 5px;
    background-color: var(--bg);
    box-shadow: 2px 2px 6px var(--dark-gray);
    border: 1px solid var(--dark-gray);
    gap: 1em;
    transition: all 0.2s ease-in-out;

    &:hover,
    &.active {
      border: 1px solid var(--bg-active);
    }

    .header-container {
      display: flex;
      gap: 1em;
      align-items: center;
    }

    .enum-variants {
      display: flex;
      flex-direction: column;
      gap: 0.5em;
      flex: 1;

      .enum-variant {
        position: relative;
        display: flex;
        gap: 0.5em;
        flex: 1 0 auto;
        background-color: var(--bg-alt);
        padding: 0.5em;
        color: var(--white);
        border-radius: 5px;
        align-items: center;
        justify-content: space-between;
        border: 1px solid black;

        .variant-label {
          color: var(--white);
          text-align: center;
          font-weight: bold;
        }

        .color-picker {
          cursor: pointer;
          background-color: var(--bg-active);

          &:hover {
            scale: 1.02;
          }
        }
      }
    }
  }

  .row-center {
    .node-view {
      background-color: var(--bg-active);

      &:hover,
      &.active {
        outline: 3px solid black;
      }

      .node-name {
        color: #222;
        font-weight: bold;
      }

      .active-container {
        display: flex;
        justify-content: center;
        align-items: center;
        color: black;
        margin-bottom: -0.5em;
        cursor: default;

        .active-inner {
          display: flex;
          align-items: center;
          justify-content: center;
          font-weight: bold;
          font-style: italic;
          color: #222;

          svg {
            width: 1em;
            margin-right: 0.5em;
          }
        }
      }
    }

    .action-container {
      outline: unset;
      background-color: var(--dark-gray);

      .status {
        color: var(--white);
        font-weight: bold;
      }
    }
  }
}

.formula-chain-container {
  display: flex;
  gap: 0.5em;
  align-items: center;
  background-color: var(--bg-active);
  padding: 0.5em;
  border-radius: 0.25em;
  outline: 1px solid black;

  .invalid-icon {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 3px;
    background-color: var(--warn);
    outline: 1px solid var(--bg-dark);
    border-radius: 50%;
    color: var(--bg-dark);

    svg {
      width: 1em;
      height: 1em;
    }
  }

  .formula-chain {
    display: flex;
    align-items: center;
    gap: 0.5em;

    button.active {
      background-color: var(--primary);
    }

    button.update-operator {
      color: var(--white);
      min-width: 1.4em;
      min-height: 1.4em;
      max-width: 1.4em;
      max-height: 1.4em;
      background-color: var(--secondary);
      border-radius: 50%;
      display: flex;
      align-items: center;
      justify-content: center;
      outline: unset;
      border: 1px solid black;
      cursor: pointer;

      svg {
        display: block;
        width: 50%;
        height: 50%;
      }
    }
  }
}
